Package com.adobe.granite.security.user
Interface UserManagementService
-
@ProviderType public interface UserManagementService
Service interface for common user management related tasks and utility methods.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.String
getAdminId()
java.lang.String
getAnonymousId()
java.lang.String
getAuthorizableRootPath()
java.lang.String
getEveryoneName()
java.lang.String
getGroupRootPath()
java.lang.String
getSystemUserRootPath()
java.lang.String
getUserInternalId(Session session)
Retrieve the user identifier of currently logged in user for eg:- jcr:uuid of logged in userUserManager
getUserManager(Session session)
Retrieve theUserManager
associated with the given session.java.lang.String
getUserRootPath()
-
-
-
Method Detail
-
getUserManager
@Nonnull UserManager getUserManager(@Nonnull Session session) throws java.lang.UnsupportedOperationException, RepositoryException
Retrieve theUserManager
associated with the given session. This method is a shortcut for callingJackrabbitSession.getUserManager()
.- Parameters:
session
- The editing session.- Returns:
- The
UserManager
associated with the given session. - Throws:
java.lang.UnsupportedOperationException
- If the specified session is not anJackrabbitSession
.RepositoryException
- If an error occurs or if the JCR repository doesn't support user managent.
-
getAuthorizableRootPath
@Nonnull java.lang.String getAuthorizableRootPath()
- Returns:
- the path of the common ancestor node for all users and groups.
-
getUserRootPath
@Nonnull java.lang.String getUserRootPath()
- Returns:
- the configured path of the user root node.
-
getGroupRootPath
@Nonnull java.lang.String getGroupRootPath()
- Returns:
- the configured path of the group root node.
-
getSystemUserRootPath
@Nonnull java.lang.String getSystemUserRootPath()
- Returns:
- the configured path of the system users root node.
-
getAnonymousId
@Nonnull java.lang.String getAnonymousId()
- Returns:
- The user ID of the anonymous (guest) user.
-
getUserInternalId
@Nonnull java.lang.String getUserInternalId(@Nonnull Session session) throws java.lang.UnsupportedOperationException, RepositoryException
Retrieve the user identifier of currently logged in user for eg:- jcr:uuid of logged in user- Parameters:
session
- The current user session- Returns:
- The user id(uuid) associated with user
- Throws:
java.lang.UnsupportedOperationException
- If the specified session is not anJackrabbitSession
or if Authorizable is not of User type.RepositoryException
- If an error occurs or user id doesnt exist or if the JCR repository doesn't support user management.
-
getAdminId
@Nonnull java.lang.String getAdminId()
- Returns:
- The user ID of the administrative user.
-
getEveryoneName
@Nonnull java.lang.String getEveryoneName()
- Returns:
- The name of the built-in everyone principal.
-
-