Package com.composum.sling.core.user
Class UserProfile
- java.lang.Object
-
- com.composum.sling.core.AbstractSlingBean
-
- com.composum.sling.core.user.UserProfile
-
- All Implemented Interfaces:
RestrictedBean
,SlingBean
public class UserProfile extends AbstractSlingBean
the user profile bean derived from the AEM user profile approach
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.composum.sling.core.AbstractSlingBean
AbstractSlingBean.NodeClosure
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
allowed
static String
NN_PROFILE
static String
PN_ABOUT
static String
PN_CITY
static String
PN_COUNTRY
static String
PN_EMAIL
static String
PN_FAMILY_NAME
static String
PN_GENDER
static String
PN_GIVEN_NAME
static String
PN_JOB_TITLE
static String
PN_PHONE_NUMBER
static String
PN_POSTAL_CODE
static String
PN_STREET
static String
PN_TITLE
static String
SERVICE_KEY
static String
USERS_ROOT
protected org.apache.sling.api.resource.ValueMap
values
-
Fields inherited from class com.composum.sling.core.AbstractSlingBean
context, queryManager, request, resolver, resource, response, session, sling
-
-
Constructor Summary
Constructors Constructor Description UserProfile()
UserProfile(BeanContext context)
UserProfile(BeanContext context, org.apache.sling.api.resource.Resource resource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull String
getAbout()
@NotNull String
getAddress()
@NotNull String
getEmail()
@NotNull String
getName()
returns the name of the resource wrapped by this bean@NotNull String
getPhoneNumber()
@NotNull org.apache.sling.api.resource.ValueMap
getValues()
void
initialize(BeanContext context, org.apache.sling.api.resource.Resource resource)
This basic initialization sets up the context and resource attributes only, all the other attributes are set 'lazy' during their getter calls.boolean
isValid()
-
Methods inherited from class com.composum.sling.core.AbstractSlingBean
executeQuery, findBeans, findNodes, findNodes, findPathList, getContentResource, getDomId, getHasTitle, getId, getInherited, getInherited, getNode, getParent, getParent, getPath, getPermissible, getProperty, getProperty, getQueryManager, getRequest, getResolver, getResource, getResponse, getServiceKey, getSession, getSling, getStringId, getTitle, getType, getUrl, getUsername, initialize, isPermissible, isReadAllowed, isWriteAllowed, toString, toString
-
-
-
-
Field Detail
-
SERVICE_KEY
public static final String SERVICE_KEY
- See Also:
- Constant Field Values
-
PN_GENDER
public static final String PN_GENDER
- See Also:
- Constant Field Values
-
PN_TITLE
public static final String PN_TITLE
- See Also:
- Constant Field Values
-
PN_GIVEN_NAME
public static final String PN_GIVEN_NAME
- See Also:
- Constant Field Values
-
PN_FAMILY_NAME
public static final String PN_FAMILY_NAME
- See Also:
- Constant Field Values
-
PN_JOB_TITLE
public static final String PN_JOB_TITLE
- See Also:
- Constant Field Values
-
PN_EMAIL
public static final String PN_EMAIL
- See Also:
- Constant Field Values
-
PN_PHONE_NUMBER
public static final String PN_PHONE_NUMBER
- See Also:
- Constant Field Values
-
PN_STREET
public static final String PN_STREET
- See Also:
- Constant Field Values
-
PN_POSTAL_CODE
public static final String PN_POSTAL_CODE
- See Also:
- Constant Field Values
-
PN_CITY
public static final String PN_CITY
- See Also:
- Constant Field Values
-
PN_COUNTRY
public static final String PN_COUNTRY
- See Also:
- Constant Field Values
-
PN_ABOUT
public static final String PN_ABOUT
- See Also:
- Constant Field Values
-
NN_PROFILE
public static final String NN_PROFILE
- See Also:
- Constant Field Values
-
USERS_ROOT
public static final String USERS_ROOT
- See Also:
- Constant Field Values
-
allowed
protected boolean allowed
-
values
protected org.apache.sling.api.resource.ValueMap values
-
-
Constructor Detail
-
UserProfile
public UserProfile(BeanContext context, org.apache.sling.api.resource.Resource resource)
-
UserProfile
public UserProfile(BeanContext context)
-
UserProfile
public UserProfile()
-
-
Method Detail
-
initialize
public void initialize(BeanContext context, org.apache.sling.api.resource.Resource resource)
Description copied from class:AbstractSlingBean
This basic initialization sets up the context and resource attributes only, all the other attributes are set 'lazy' during their getter calls.- Specified by:
initialize
in interfaceSlingBean
- Overrides:
initialize
in classAbstractSlingBean
- Parameters:
context
- the scripting context (e.g. a JSP PageContext or a Groovy scripting context)resource
- the resource to use (normally the resource addressed by the request)- See Also:
BeanContext.withResource(Resource)
-
getValues
@NotNull public @NotNull org.apache.sling.api.resource.ValueMap getValues()
-
isValid
public boolean isValid()
-
getName
@NotNull public @NotNull String getName()
Description copied from interface:SlingBean
returns the name of the resource wrapped by this bean- Specified by:
getName
in interfaceSlingBean
- Overrides:
getName
in classAbstractSlingBean
-
getEmail
@NotNull public @NotNull String getEmail()
-
getPhoneNumber
@NotNull public @NotNull String getPhoneNumber()
-
getAddress
@NotNull public @NotNull String getAddress()
-
getAbout
@NotNull public @NotNull String getAbout()
-
-