Example usage for com.liferay.portal.kernel.service RoleLocalServiceUtil hasGroupRoles

List of usage examples for com.liferay.portal.kernel.service RoleLocalServiceUtil hasGroupRoles

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.service RoleLocalServiceUtil hasGroupRoles.

Prototype

public static boolean hasGroupRoles(long groupId) 

Source Link

Usage

From source file:com.liferay.users.admin.web.internal.display.context.UserDisplayContext.java

License:Open Source License

public List<Group> getRoleGroups() throws PortalException {
    List<Group> allGroups = getAllGroups();

    Stream<Group> stream = allGroups.stream();

    stream = stream.filter(group -> RoleLocalServiceUtil.hasGroupRoles(group.getGroupId()));

    return stream.collect(Collectors.toList());
}