Package org.exoplatform.portal.config
Class DefaultGroupVisibilityPlugin
java.lang.Object
org.exoplatform.container.component.BaseComponentPlugin
org.exoplatform.portal.config.GroupVisibilityPlugin
org.exoplatform.portal.config.DefaultGroupVisibilityPlugin
- All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin
Default implementation of GroupVisibilityPlugin which allows to see a group
if any of these conditions is fulfilled:
* the given user is the super user
* the given user is a platform administrator
* the given user is a manager of the group
-
Field Summary
Fields inherited from class org.exoplatform.container.component.BaseComponentPlugin
desc, name -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanhasPermission(org.exoplatform.services.security.Identity userIdentity, org.exoplatform.services.organization.Group group) Check if the given identity can see the given group.Methods inherited from class org.exoplatform.container.component.BaseComponentPlugin
getDescription, getName, setDescription, setName
-
Constructor Details
-
DefaultGroupVisibilityPlugin
-
-
Method Details
-
hasPermission
public boolean hasPermission(org.exoplatform.services.security.Identity userIdentity, org.exoplatform.services.organization.Group group) Check if the given identity can see the given group. The methods org.exoplatform.services.security.Identity.isMemberOf(String, String) and org.exoplatform.portal.config.UserACL.hasPermission(Identity, String) are not used to return parent groups as well, in order to return a complete groups tree.- Specified by:
hasPermissionin classGroupVisibilityPlugin- Parameters:
userIdentity- The user identitygroup- The group to check- Returns:
- true if the user identity has permission to see the given group
-