public interface UserPropertiesManager
UserPropertiesManager
interface provides access to
UserProperties
associated with a given authorizable.Modifier and Type | Method and Description |
---|---|
UserProperties |
createUserProperties(String authorizableId,
String relPath)
Create a new instance of
UserProperties . |
Iterator<UserProperties> |
getMemberOfUserProperties(String authorizableId,
String relPath,
boolean declaredOnly)
Returns an iterator over the properties of all groups that the authorizable with
authorizableId is
a member of. |
Iterator<UserProperties> |
getMemberUserProperties(Group group,
String relPath,
boolean declaredOnly)
Returns an iterator over the user properties of all members of the given group.
|
UserProperties |
getUserProperties(Authorizable authorizable,
String relPath)
Retrieve the user properties identified by the given relative path and
the specified authorizable.
|
UserProperties |
getUserProperties(Node userPropertiesNode)
Retrieve the user properties identified by the given node.
|
UserProperties |
getUserProperties(String authorizableId,
String relPath)
Retrieve the user properties identified by the given relative path and
the specified authorizable ID.
|
UserPropertiesComposite |
getUserPropertiesComposite(String authorizableId,
String[] relPaths)
Retrieves a composite (aggregation) of
UserProperties associated with the authorizable identified by the
given authorizableId and corresponding to and in the order of the given relPaths . |
UserPropertiesComposite |
getUserPropertiesComposite(String authorizableId,
UserPropertiesFilter filter)
Retrieves a composite (aggregation) of
UserProperties associated with the authorizable identified by the
given authorizableId and included by the given filter . |
UserProperties createUserProperties(String authorizableId, String relPath) throws RepositoryException
UserProperties
. Please note that
Session
must be called by the editing JCR
session in order to persist the new user properties.authorizableId
- The ID of the associated authorizable.relPath
- A name or relative path identifying the new user properties.UserProperties
instance. Note that the
associated JCR node will be NEW
until
Session.save
is called to persist the changes.javax.jcr.RepositoryException
- If an error occurs or the specified
relative path is invalid.RepositoryException
UserProperties getUserProperties(String authorizableId, String relPath) throws RepositoryException
authorizableId
- Identifier of the target authorizable.relPath
- A name or relative path identifying the user properties.UserProperties
or null
if the authorizable does not exist or it has no user properties at the
specified relative path.RepositoryException
- If an error occurs or the specified
relative path is invalid.UserProperties getUserProperties(Authorizable authorizable, String relPath) throws RepositoryException
authorizable
- The target authorizable.relPath
- A name or relative path identifying the user properties.UserProperties
or null
if the authorizable has no user properties at the specified relative path.RepositoryException
- If an error occurs or the specified
relative path is invalid.UserProperties getUserProperties(Node userPropertiesNode) throws RepositoryException
userPropertiesNode
- The node representing the user properties.RepositoryException
- If an exception occurs or if the given node
does not represent valid user properties (e.g. not associated with an
authorizable).UserPropertiesComposite getUserPropertiesComposite(String authorizableId, String[] relPaths) throws RepositoryException
UserProperties
associated with the authorizable identified by the
given authorizableId
and corresponding to and in the order of the given relPaths
. The
ordering is relevant for e.g. accessing a property found on multiple user property nodes, in which case it is
inherited according to the order (last has precedence).authorizableId
- The ID of the Authorizable
for which to retrieve the user properties composite.relPaths
- An array of strings denoting the desired relative paths of the user property nodes and
their order in which to be included in the composite.UserProperties
.RepositoryException
- If an error occurs during repository access or no authorizable was found with the
given authorizableId
.UserPropertiesComposite getUserPropertiesComposite(String authorizableId, UserPropertiesFilter filter) throws RepositoryException
UserProperties
associated with the authorizable identified by the
given authorizableId
and included by the given filter
.authorizableId
- The ID of the Authorizable
for which to retrieve the user properties composite.filter
- A UserPropertiesFilter
by which user properties are included or excluded.UserPropertiesComposite
containing the UserProperties
included by the filter.RepositoryException
- If an error occurs during repository access or no authorizable was found with the
given authorizableId
.Iterator<UserProperties> getMemberOfUserProperties(String authorizableId, String relPath, boolean declaredOnly) throws RepositoryException
authorizableId
is
a member of. please note that only groups are included of which the underlying session has read access to.authorizableId
- the id of the authorizablerelPath
- the relative path to build the user properties fromdeclaredOnly
- if true
only declared groups are includedRepositoryException
- if an error occurrsAuthorizable.memberOf()
,
Authorizable.declaredMemberOf()
Iterator<UserProperties> getMemberUserProperties(Group group, String relPath, boolean declaredOnly) throws RepositoryException
group
- the group to retrieve the members fromrelPath
- the relative path to build the user properties fromdeclaredOnly
- if true
only delcated members are includedRepositoryException
- if an error occurrsGroup.getMembers()
,
Group.getDeclaredMembers()
"Copyright © 2006 - 2015 Adobe Systems Incorporated. All Rights Reserved"