Package com.sun.identity.entitlement
Interface SubjectAttributesCollector
-
- All Known Implementing Classes:
OpenSSOSubjectAttributesCollector
public interface SubjectAttributesCollectorInterface class for obtaining attributes for users. Implementations of this class would be called during authorization to obtain users' attributes and memberships.
-
-
Field Summary
Fields Modifier and Type Field Description static StringATTR_NAME_ALL_ENTITIESAll Entities.static StringNAMESPACE_ATTRAttribute Namespace.static StringNAMESPACE_IDENTITYIdentity Namespace
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Map<String,Set<String>>getAttributes(Subject subject, Set<String> attrNames)Returns the attribute values of the given user represented bySubject object.Set<String>getAvailableSubjectAttributeNames()Returns available subject attribute names.Map<String,Set<String>>getUserAttributes(Subject subject, Set<String> attrNames)Returns the attribute values of the given user represented bySubject object.voidinit(String realm, Map<String,Set<String>> configMap)Initializes this object with specified parameters.booleanisGroupMembershipSearchIndexEnabled()Returns true if group membership search index is enabled or false otherwise.
-
-
-
Field Detail
-
NAMESPACE_ATTR
static final String NAMESPACE_ATTR
Attribute Namespace.- See Also:
- Constant Field Values
-
NAMESPACE_IDENTITY
static final String NAMESPACE_IDENTITY
Identity Namespace- See Also:
- Constant Field Values
-
ATTR_NAME_ALL_ENTITIES
static final String ATTR_NAME_ALL_ENTITIES
All Entities.- See Also:
- Constant Field Values
-
-
Method Detail
-
init
void init(String realm, Map<String,Set<String>> configMap)
Initializes this object with specified parameters.- Parameters:
realm- the realmconfigMap- configuration map
-
getAttributes
Map<String,Set<String>> getAttributes(Subject subject, Set<String> attrNames) throws EntitlementException
Returns the attribute values of the given user represented bySubject object.- Parameters:
subject- identity of the userattrNames- requested attribute names- Returns:
- a map of attribute names and their values
- Throws:
EntitlementException- if this operation failed.
-
getAvailableSubjectAttributeNames
Set<String> getAvailableSubjectAttributeNames() throws EntitlementException
Returns available subject attribute names.- Returns:
- a set of available subject attribute names or empty CaseInsensitiveHashSet if not found
- Throws:
EntitlementException
-
isGroupMembershipSearchIndexEnabled
boolean isGroupMembershipSearchIndexEnabled()
Returns true if group membership search index is enabled or false otherwise.- Returns:
- true if group membership search index is enabled or false otherwise.
-
getUserAttributes
Map<String,Set<String>> getUserAttributes(Subject subject, Set<String> attrNames) throws EntitlementException
Returns the attribute values of the given user represented bySubject object.- Parameters:
subject- identity of the user.attrNames- requested attribute names.- Returns:
- a map of attribute names and their values
- Throws:
EntitlementException- if this operation failed.
-
-