public class AuthorizableUtil
extends java.lang.Object
Constructor and Description |
---|
AuthorizableUtil() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getFormattedName(ResourceResolver resolver,
Authorizable authorizable)
Utility to retrieve the formatted name of a user.
|
static java.lang.String |
getFormattedName(ResourceResolver resolver,
Authorizable authorizable,
java.lang.String nameDisplayOrder)
Utility to retrieve the formatted name of a user
|
static java.lang.String |
getFormattedName(ResourceResolver resolver,
java.lang.String userId)
Utility to retrieve the formatted name of a user.
|
static java.lang.String |
getFormattedName(ResourceResolver resolver,
java.lang.String userId,
java.lang.String nameDisplayOrder)
Utility to retrieve the formatted name of a user.
|
static java.lang.String |
getName(Authorizable authorizable)
Deprecated.
since AEM6.4 because it is not multiple profile aware. Please use
getFormattedName(ResourceResolver, Authorizable) |
static UserProperties |
getProfile(UserPropertiesManager userPropertiesManager,
java.lang.String authorizableId) |
public static UserProperties getProfile(UserPropertiesManager userPropertiesManager, java.lang.String authorizableId) throws RepositoryException
RepositoryException
@Deprecated public static java.lang.String getName(Authorizable authorizable) throws RepositoryException
getFormattedName(ResourceResolver, Authorizable)
authorizable
- the authorizableRepositoryException
- in case of a failurepublic static java.lang.String getFormattedName(ResourceResolver resolver, java.lang.String userId)
getFormattedName(ResourceResolver, Authorizable)
if possible.resolver
- Resource resolver to use to get the UserPropertiesManager
userId
- ID of the user to get the display name frompublic static java.lang.String getFormattedName(ResourceResolver resolver, Authorizable authorizable)
resolver
- Resource resolver to use to get the UserPropertiesManager
authorizable
- the authorizablepublic static java.lang.String getFormattedName(ResourceResolver resolver, java.lang.String userId, java.lang.String nameDisplayOrder)
getFormattedName(ResourceResolver, Authorizable, String)
if possible.resolver
- Resource resolver to use to get the UserPropertiesManager
userId
- ID of the user to get the display name fromnameDisplayOrder
- Order of given, middle and family names.
Western name order should be "givenName middleName familyName",
Eastern name order should be "familyName givenName middleName".public static java.lang.String getFormattedName(ResourceResolver resolver, Authorizable authorizable, java.lang.String nameDisplayOrder)
resolver
- Resource resolver to use to get the UserPropertiesManager
authorizable
- the authorizablenameDisplayOrder
- Order of given, middle and family names.
Western name order should be "givenName middleName familyName",
Eastern name order should be "familyName givenName middleName"."Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"