Package com.iplanet.am.sdk
Interface AMObject
-
- All Superinterfaces:
AMConstants
- All Known Subinterfaces:
AMAssignableDynamicGroup,AMDynamicGroup,AMFilteredRole,AMGroup,AMGroupContainer,AMOrganization,AMOrganizationalUnit,AMPeopleContainer,AMResource,AMRole,AMStaticGroup,AMTemplate,AMUser
- All Known Implementing Classes:
AMEntityImpl
public interface AMObject extends AMConstants
Deprecated.As of Sun Java System Access Manager 7.1.TheAMObjectinterface provides methods to manage various Sun Java System Access Manager objects and their attributes.
-
-
Field Summary
Fields Modifier and Type Field Description static intACTIVEDeprecated.Represents the status of an object as activestatic StringACTIVE_VALUEDeprecated.String representation of the "active" statestatic intASSIGNABLE_DYNAMIC_GROUPDeprecated.Represents a Dynamic Group object typestatic intDELETEDDeprecated.Represents the status of an object as "deleted"static StringDELETED_VALUEDeprecated.String representation of the "deleted" statestatic intDYNAMIC_GROUPDeprecated.Represents a Dynamic Group object typestatic intFILTERED_ROLEDeprecated.Represents a Filtered Role object typestatic intGROUPDeprecated.Represents a Group object typestatic intGROUP_CONTAINERDeprecated.Represents a group container object typestatic intGROUP_PROFILEDeprecated.Represents group profile Informationstatic intINACTIVEDeprecated.Represents the status of an object as inactivestatic StringINACTIVE_VALUEDeprecated.String representation of the "inactive" statestatic intMANAGED_ROLEDeprecated.Represents a Managed Role object typestatic intORGANIZATIONDeprecated.Represents an Organization object typestatic intORGANIZATIONAL_UNITDeprecated.Represents a Organizational Unit object typestatic intPEOPLE_CONTAINERDeprecated.Represents a People Container object typestatic intPOLICYDeprecated.Represents Policy Informationstatic intRESOURCEDeprecated.Represents resource object typestatic intROLEDeprecated.Represents a Role object typestatic intROLE_PROFILEDeprecated.Represents role profile Informationstatic intSERVICEDeprecated.Represents Service Informationstatic intSTATIC_GROUPDeprecated.Represents a Static Group object typestatic intTEMPLATEDeprecated.Represents a Template object typestatic intUNDETERMINED_OBJECT_TYPEDeprecated.Used to indicate the object type has not yet determined.static intUNKNOWN_OBJECT_TYPEDeprecated.Represents an object type that cannot be identifiedstatic intUSERDeprecated.Represents a User object type-
Fields inherited from interface com.iplanet.am.sdk.AMConstants
ADD_MEMBER, ADMIN_GROUPS_ENABLED_ATTR, ADMIN_ROLE_ATTR, ADMINISTRATION_SERVICE, CACHE_ENABLED_DISABLED_KEY, CACHE_MAX_SIZE_KEY, COMPLIANCE_SPECIAL_FILTER_ATTR, COMPLIANCE_USER_DELETION_ATTR, CONTAINER_DEFAULT_TEMPLATE_ROLE, CONTAINER_SUPPORTED_TYPES_ATTRIBUTE, DCT_ATTRIBUTE_LIST_ATTR, DCT_ENABLED_ATTR, DOMAIN_ADMINISTRATORS, DOMAIN_HELP_DESK_ADMINISTRATORS, EMAIL_ATTRIBUTE, FILTER_ATTR_NAME, INET_ADMIN_OBJECT_CLASS, INET_DOMAIN_STATUS_ATTR, INET_DOMAIN_STATUS_ATTRIBUTE, INVALID_USERID_CHARACTERS, OTHER_COSATTR_TYPE, POLICY_COSATTR_TYPE, POLICY_SUFFIX, PRE_POST_PROCESSING_MODULES_ATTR, REMOVE_ATTRIBUTE, REMOVE_MEMBER, REQUIRED_SERVICES_ATTR, ROLE_MANAGED_CONTAINER_DN_ATTRIBUTE, SCOPE_BASE, SCOPE_ONE, SCOPE_SUB, SERVICE_STATUS_ATTRIBUTE, STATIC_GROUP_DN_ATTRIBUTE, SUBSCRIBABLE_ATTRIBUTE, UNIQUE_ATTRIBUTE_LIST_ATTRIBUTE, UNIQUE_MEMBER_ATTRIBUTE, USER_CREATE_NOTIFICATION_LIST, USER_DELETE_NOTIFICATION_LIST, USER_ENCRYPTED_PASSWORD_ATTRIBUTE, USER_ENTRY_PROCESSING_IMPL, USER_MODIFY_NOTIFICATION_LIST, USER_PASSWORD_ATTRIBUTE, USER_SEARCH_RETURN_ATTR, USERID_PASSWORD_VALIDATION_CLASS
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description voidaddEventListener(AMEventListener listener)Deprecated.Registers a event listener that needs to be invoked when a relevant event occurs.voidassignPolicies(String serviceName, Set policyDNs)Deprecated.This method has been deprecated.voidassignServices(Map serviceNameAndAttrs)Deprecated.Assign services to the entity (user/group/organization/organization unit).AMTemplatecreatePolicyTemplate(String serviceName, Map attributes)Deprecated.usecom.sun.identity.policypackage for creating and managing policies.AMTemplatecreatePolicyTemplate(String serviceName, Map attributes, int priority)Deprecated.usecom.sun.identity.policypackage for creating and managing policies.AMTemplatecreateTemplate(int templateType, String serviceName, Map attributes)Deprecated.Creates a Template with no priority for the given service associated with thisAMObject.AMTemplatecreateTemplate(int templateType, String serviceName, Map attributes, int priority)Deprecated.Creates a Template with a priority for the given service associated with thisAMObject.voiddelete()Deprecated.Deletes the object.voiddelete(boolean recursive)Deprecated.Deletes object(s).SetgetAssignedServices()Deprecated.Returns all service names that are assigned to the user/group/organization/organizational unit.SetgetAttribute(String attributeName)Deprecated.Returns attribute value.byte[][]getAttributeByteArray(String attributeName)Deprecated.Returns attribute value.MapgetAttributes()Deprecated.Returns Map of all attributes.MapgetAttributes(Set attributeNames)Deprecated.Returns Map of specified attributes.MapgetAttributesByteArray()Deprecated.Returns Map of all attributes.MapgetAttributesByteArray(Set attributeNames)Deprecated.Returns Map of specified attributes.MapgetAttributesFromDataStore()Deprecated.Returns Map of all attributes directly from data store.MapgetAttributesFromDataStore(Set attributeNames)Deprecated.Returns Map of specified attributes directly from data store.StringgetDN()Deprecated.Returns the DN of the entry.StringgetOrganizationDN()Deprecated.Returns the object's organization.StringgetParentDN()Deprecated.Returns the parent DN of the entry.MapgetPolicy(String serviceName)Deprecated.This method has been deprecated.AMTemplategetPolicyTemplate(String serviceName)Deprecated.This method has been deprecated.MapgetServiceAttributes(String serviceName)Deprecated.This method has been deprecated.StringgetServiceStatus(String serviceName)Deprecated.Get the status of the service for this entity (user/group/organization/ organizational unit).StringgetStringAttribute(String attributeName)Deprecated.Returns string type attribute value.AMTemplategetTemplate(String serviceName, int templateType)Deprecated.Returns the Template for the given service associated with thisAMObject.booleanisExists()Deprecated.Checks if the entry exists in the directory or not.voidmodifyService(String serviceName, Map attrMap)Deprecated.Modify the service attributes of a service assigned to a entity (user/group/organization/organizational unit).voidpurge(boolean recursive, int graceperiod)Deprecated.This method will physically delete the entry from the data store.voidremoveAttributes(Set attributes)Deprecated.Removes attributes in thisAMObject.voidremoveEventListener(AMEventListener listener)Deprecated.Unregisters a previously registered event listener.Setsearch(int level, String filter)Deprecated.Search objects based on specified level and filter.voidsetAttributeByteArray(String attrName, byte[][] byteValues)Deprecated.Sets byte attribute values in thisAMObject.voidsetAttributes(Map attributes)Deprecated.Sets attribute values in thisAMObject.voidsetAttributesByteArray(Map attributes)Deprecated.Sets byte attribute values in thisAMObject.voidsetServiceStatus(String serviceName, String status)Deprecated.Set the status of the service for this entity (User/Organization /Group/Organizational Unit).voidsetStringAttribute(String attributeName, String value)Deprecated.Sets string type attribute value.voidstore()Deprecated.Stores the change to directory server.voidstore(boolean addValues)Deprecated.Stores the change to directory server.voidunassignPolicies(String serviceName, Set policyDNs)Deprecated.This method has been deprecated.voidunassignServices(Set serviceNames)Deprecated.Unassigns services from the user/group/organization/ organizational unit.
-
-
-
Field Detail
-
USER
static final int USER
Deprecated.Represents a User object type- See Also:
- Constant Field Values
-
ORGANIZATION
static final int ORGANIZATION
Deprecated.Represents an Organization object type- See Also:
- Constant Field Values
-
ORGANIZATIONAL_UNIT
static final int ORGANIZATIONAL_UNIT
Deprecated.Represents a Organizational Unit object type- See Also:
- Constant Field Values
-
GROUP_CONTAINER
static final int GROUP_CONTAINER
Deprecated.Represents a group container object type- See Also:
- Constant Field Values
-
PEOPLE_CONTAINER
static final int PEOPLE_CONTAINER
Deprecated.Represents a People Container object type- See Also:
- Constant Field Values
-
ROLE
static final int ROLE
Deprecated.Represents a Role object type- See Also:
- Constant Field Values
-
MANAGED_ROLE
static final int MANAGED_ROLE
Deprecated.Represents a Managed Role object type- See Also:
- Constant Field Values
-
FILTERED_ROLE
static final int FILTERED_ROLE
Deprecated.Represents a Filtered Role object type- See Also:
- Constant Field Values
-
GROUP
static final int GROUP
Deprecated.Represents a Group object type- See Also:
- Constant Field Values
-
STATIC_GROUP
static final int STATIC_GROUP
Deprecated.Represents a Static Group object type- See Also:
- Constant Field Values
-
DYNAMIC_GROUP
static final int DYNAMIC_GROUP
Deprecated.Represents a Dynamic Group object type- See Also:
- Constant Field Values
-
ASSIGNABLE_DYNAMIC_GROUP
static final int ASSIGNABLE_DYNAMIC_GROUP
Deprecated.Represents a Dynamic Group object type- See Also:
- Constant Field Values
-
TEMPLATE
static final int TEMPLATE
Deprecated.Represents a Template object type- See Also:
- Constant Field Values
-
POLICY
static final int POLICY
Deprecated.Represents Policy Information- See Also:
- Constant Field Values
-
SERVICE
static final int SERVICE
Deprecated.Represents Service Information- See Also:
- Constant Field Values
-
ROLE_PROFILE
static final int ROLE_PROFILE
Deprecated.Represents role profile Information- See Also:
- Constant Field Values
-
GROUP_PROFILE
static final int GROUP_PROFILE
Deprecated.Represents group profile Information- See Also:
- Constant Field Values
-
RESOURCE
static final int RESOURCE
Deprecated.Represents resource object type- See Also:
- Constant Field Values
-
ACTIVE
static final int ACTIVE
Deprecated.Represents the status of an object as active- See Also:
- Constant Field Values
-
ACTIVE_VALUE
static final String ACTIVE_VALUE
Deprecated.String representation of the "active" state- See Also:
- Constant Field Values
-
INACTIVE
static final int INACTIVE
Deprecated.Represents the status of an object as inactive- See Also:
- Constant Field Values
-
INACTIVE_VALUE
static final String INACTIVE_VALUE
Deprecated.String representation of the "inactive" state- See Also:
- Constant Field Values
-
DELETED
static final int DELETED
Deprecated.Represents the status of an object as "deleted"- See Also:
- Constant Field Values
-
DELETED_VALUE
static final String DELETED_VALUE
Deprecated.String representation of the "deleted" state- See Also:
- Constant Field Values
-
UNKNOWN_OBJECT_TYPE
static final int UNKNOWN_OBJECT_TYPE
Deprecated.Represents an object type that cannot be identified- See Also:
- Constant Field Values
-
UNDETERMINED_OBJECT_TYPE
static final int UNDETERMINED_OBJECT_TYPE
Deprecated.Used to indicate the object type has not yet determined. Mainly used in caching. Local to this package- See Also:
- Constant Field Values
-
-
Method Detail
-
getDN
String getDN()
Deprecated.Returns the DN of the entry.- Returns:
- String DN
-
getParentDN
String getParentDN()
Deprecated.Returns the parent DN of the entry.- Returns:
- String DN
-
store
void store() throws AMException, SSOExceptionDeprecated.Stores the change to directory server. This method should be called after doingsetAttributesso that the changes that are made can be permanently committed to the LDAP data store.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.
-
store
void store(boolean addValues) throws AMException, SSOExceptionDeprecated.Stores the change to directory server. This method should be called after doingsetAttributesor any otherset methodsprovided. so that the changes that are made can be permanently committed to the LDAP data store.- Parameters:
addValues- IfaddValuesis true, then the attribute values as set in thesetAttributesmethod are added to any existing values for the same attribute in the directory. Otherwise, the attribute values replace existing values in the data store.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.
-
isExists
boolean isExists() throws SSOExceptionDeprecated.Checks if the entry exists in the directory or not. First a syntax check is done on the DN string corresponding to the entry. If the DN syntax is valid, a directory call will be made to check for the existence of the entry.NOTE: This method internally invokes a call to the directory to verify the existence of the entry. There could be a performance overhead. Hence, please use your discretion while using this method.
- Returns:
- false if the entry does not have a valid DN syntax or if the entry does not exists in the Directory. False otherwise.
- Throws:
SSOException- if the single sign on token is no longer valid.
-
getAttributes
Map getAttributes() throws AMException, SSOException
Deprecated.Returns Map of all attributes. Map key is the attribute name and value is the attribute value.- Returns:
- Map of all attributes.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.
-
getAttributesFromDataStore
Map getAttributesFromDataStore() throws AMException, SSOException
Deprecated.Returns Map of all attributes directly from data store. Map key is the attribute name and value is the attribute value.- Returns:
- Map of all attributes.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttributesByteArray
Map getAttributesByteArray() throws AMException, SSOException
Deprecated.Returns Map of all attributes. Map key is the attribute name and value is the attribute value in byte[][] format.- Returns:
- Map of all attributes.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttributes
Map getAttributes(Set attributeNames) throws AMException, SSOException
Deprecated.Returns Map of specified attributes. Map key is the attribute name and value is the attribute value.- Parameters:
attributeNames- The Set of attribute names.- Returns:
- Map of specified attributes.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttributesFromDataStore
Map getAttributesFromDataStore(Set attributeNames) throws AMException, SSOException
Deprecated.Returns Map of specified attributes directly from data store. Map key is the attribute name and value is the attribute value.- Parameters:
attributeNames- The Set of attribute names.- Returns:
- Map of specified attributes.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttributesByteArray
Map getAttributesByteArray(Set attributeNames) throws AMException, SSOException
Deprecated.Returns Map of specified attributes. Map key is the attribute name and value is the attribute value in byte[][] format.- Parameters:
attributeNames- The Set of attribute names.- Returns:
- Map of specified attributes. The key of the map is the attribute name and the values in byte[][] format.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttribute
Set getAttribute(String attributeName) throws AMException, SSOException
Deprecated.Returns attribute value.- Parameters:
attributeName- Attribute name- Returns:
- Set of attribute values.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getAttributeByteArray
byte[][] getAttributeByteArray(String attributeName) throws AMException, SSOException
Deprecated.Returns attribute value.- Parameters:
attributeName- Attribute name- Returns:
- attribute values in byte[][] format or null if the attribute does not exist.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getStringAttribute
String getStringAttribute(String attributeName) throws AMException, SSOException
Deprecated.Returns string type attribute value.- Parameters:
attributeName- Attribute name- Returns:
- String value of attribute
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
getServiceAttributes
Map getServiceAttributes(String serviceName) throws AMException, SSOException
Deprecated.This method has been deprecated. Please use service template objects to obtain service attributes.Returns Map of all attributes of specified service. Map key is the attribute name and value is the attribute value.- Parameters:
serviceName- Service name- Returns:
- Map of all attributes of specified service, an empty Map will be returned if no service attribute is defined in the specified service.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.- See Also:
getTemplate(java.lang.String, int)
-
createTemplate
AMTemplate createTemplate(int templateType, String serviceName, Map attributes) throws UnsupportedOperationException, AMException, SSOException
Deprecated.Creates a Template with no priority for the given service associated with thisAMObject.- Parameters:
templateType- the template type. Can be one of the following:serviceName- service nameattributes- Map of attributes name-value pairs. if it is null default values will be used.- Returns:
AMTemplatethe service template for thisAMObject.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.UnsupportedOperationException- if the class implementing this interface does not support this method.
-
createTemplate
AMTemplate createTemplate(int templateType, String serviceName, Map attributes, int priority) throws UnsupportedOperationException, AMException, SSOException
Deprecated.Creates a Template with a priority for the given service associated with thisAMObject.- Parameters:
templateType- the template type. Can be one of the following:serviceName- service name.attributes- Map of attributes name-value pairspriority- template priority (0 is the highest priority)- Returns:
AMTemplatethe service template for thisAMObject.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.UnsupportedOperationException- if the class implementing this interface does not support this method
-
getTemplate
AMTemplate getTemplate(String serviceName, int templateType) throws UnsupportedOperationException, AMException, SSOException
Deprecated.Returns the Template for the given service associated with thisAMObject.- Parameters:
serviceName- service name.templateType- the template type. Can be one of the following:- Returns:
AMTemplatethe service template for thisAMObject.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.UnsupportedOperationException- if the class implementing this interface does not support this method
-
assignPolicies
void assignPolicies(String serviceName, Set policyDNs) throws AMException, SSOException
Deprecated.This method has been deprecated. Please use:com.sun.identity.policypackage for creating and managing policies.Assigns the given policies to this object.- Parameters:
serviceName- service name.policyDNs- Set of policy DN string- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
unassignPolicies
void unassignPolicies(String serviceName, Set policyDNs) throws AMException, SSOException
Deprecated.This method has been deprecated. Please use:com.sun.identity.policypackage for creating and managing policies.Unassigns the given policies from this object.- Parameters:
serviceName- service name.policyDNs- Set of policy DN string- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
setAttributeByteArray
void setAttributeByteArray(String attrName, byte[][] byteValues) throws AMException, SSOException
Deprecated.Sets byte attribute values in thisAMObject. Note that this method sets or replaces the attribute value with the new value supplied. Also, the attributes changed by this method are not committed to the LDAP data store unless the methodstore()is called explicitly.- Parameters:
attrName- the attribute namebyteValues- attribute values in byte[][] format- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
setAttributesByteArray
void setAttributesByteArray(Map attributes) throws AMException, SSOException
Deprecated.Sets byte attribute values in thisAMObject. Note that this method sets or replaces the attribute value with the new value supplied. Also, the attributes changed by this method are not committed to the LDAP data store unless the methodstore()is called explicitly.- Parameters:
attributes- Map where key is the attribute name and values are in byte[][] format.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
setAttributes
void setAttributes(Map attributes) throws AMException, SSOException
Deprecated.Sets attribute values in thisAMObject. Note that this method sets or replaces the attribute value with the new value supplied. Also, the attributes changed by this method are not committed to the LDAP data store unless the methodstore()is called explicitly.- Parameters:
attributes- Map where key is the attribute name and value is a Set of attribute values. Each of the attribute value must be a string value.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
removeAttributes
void removeAttributes(Set attributes) throws AMException, SSOException
Deprecated.Removes attributes in thisAMObject. The attributes are removed from the LDAP data store- Parameters:
attributes- The Set of attribute names- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
setStringAttribute
void setStringAttribute(String attributeName, String value) throws AMException, SSOException
Deprecated.Sets string type attribute value.- Parameters:
attributeName- attribute namevalue- value to be set for the attribute names.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.
-
delete
void delete() throws AMException, SSOExceptionDeprecated.Deletes the object.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.- See Also:
delete(boolean),purge(boolean, int)
-
delete
void delete(boolean recursive) throws AMException, SSOExceptionDeprecated.Deletes object(s). This method takes a boolean parameter, if its value is true, will remove the object and any objects under it, otherwise, will try to remove the object only. Two notes on recursive delete. First, be aware of the PERFORMANCE hit when large amount of child objects present. In the soft-delete mode, this method will mark the following objects for deletion:Organization, Group, Userpurge()should be used to physically delete this object.- Parameters:
recursive- if true delete the object and any objects under it, otherwise, delete the object only.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.- See Also:
purge(boolean, int)
-
search
Set search(int level, String filter) throws AMException, SSOException
Deprecated.Search objects based on specified level and filter.- Parameters:
level- The search level starting from the objectfilter- The search filter- Returns:
- Set of object DN's matching the search
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.
-
addEventListener
void addEventListener(AMEventListener listener) throws SSOException
Deprecated.Registers a event listener that needs to be invoked when a relevant event occurs. If the listener was already registered, then it is registered only once; no duplicate registration is allowed.Object.equals()method on the listener object is used to determine duplicates.- Parameters:
listener- listener object that will be called upon when an event occurs.- Throws:
SSOException- if errors were encountered in adding a newSSOTokenListenerinstance
-
removeEventListener
void removeEventListener(AMEventListener listener)
Deprecated.Unregisters a previously registered event listener. If thelistenerwas not registered previously, the method simply returns without doing anything.- Parameters:
listener- listener object that will be removed or unregistered.
-
createPolicyTemplate
AMTemplate createPolicyTemplate(String serviceName, Map attributes) throws UnsupportedOperationException, AMException, SSOException
Deprecated.usecom.sun.identity.policypackage for creating and managing policies.Creates a Policy Template with no priority for the given service associated with thisAMObject. This is a convenience method and is equivalent tocreateTemplate( AMTemplate.POLICY_TEMPLATE, serviceName, attributes).- Parameters:
serviceName- service name.attributes- Map of attributes name-value pairs.- Returns:
AMTemplatethe service template for thisAMObject.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid.UnsupportedOperationException- if the class implementing this interface does not support this method.
-
createPolicyTemplate
AMTemplate createPolicyTemplate(String serviceName, Map attributes, int priority) throws UnsupportedOperationException, AMException, SSOException
Deprecated.usecom.sun.identity.policypackage for creating and managing policies.Creates a Policy Template with a priority for the given service associated with thisAMObject. This is a convenience method and is equivalent tocreateTemplate(AMTemplate.POLICY_TEMPLATE, serviceName, attributes, priority).- Parameters:
serviceName- service name.attributes- Map of attributes name-value pairs.priority- template priority (0 is the highest priority).- Returns:
AMTemplatethe service template for thisAMObject.- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid.UnsupportedOperationException- if the class implementing this interface does not support this method.
-
getPolicyTemplate
AMTemplate getPolicyTemplate(String serviceName) throws UnsupportedOperationException, AMException, SSOException
Deprecated.This method has been deprecated. Please use:com.sun.identity.policypackage for creating and managing policies.Returns the policy template for a service defined for this object ignoring any inheritance. This is a convenience method and is equivalent togetTemplate(serviceName, AMTemplate.POLICY_TEMPLATE).AMUserobject will throwUnsupportedOperationExceptionbecause this method is not relevant forAMUser.- Parameters:
serviceName- service name.- Returns:
AMTemplatethe policy template of the service for this object.- Throws:
UnsupportedOperationException- if the class implementing this interface does not support this method.AMException- if an error is encountered when trying to access/retrieve data from the data store.SSOException- if the single sign on token is no longer valid
-
getPolicy
Map getPolicy(String serviceName) throws UnsupportedOperationException, AMException, SSOException
Deprecated.This method has been deprecated. Please use:com.sun.identity.policypackage for creating and managing policies.Returns the effective service policy defined at this object after considering any inheritance from any policy templates.- Parameters:
serviceName- service name.- Returns:
- Map the effective service policy for the object after inheritance; key is the attribute name and value is attribute value. An empty Map will be returned if no policy attribute is defined in the specified service.
- Throws:
UnsupportedOperationException- if the class implementing this interface does not support this methodAMException- if an error is encountered when trying to access/retrieve data from the data storeSSOException- if the single sign on token is no longer valid
-
getOrganizationDN
String getOrganizationDN() throws AMException, SSOException
Deprecated.Returns the object's organization. NOTE: Obtaining an organization DN involves considerable overhead. Hence after obtaining the organization DN, each object saves this information. Consecutives method calls on this object fetch the value stored in the object. Creating a newAMObjectinstance every time to obtain the organization DN is not recommended.- Returns:
- The object's organization DN.
- Throws:
AMException- if an error is encountered when trying to access/retrieve data from the data store or the object does not have organization DN.SSOException- if the single sign on token is no longer valid.
-
assignServices
void assignServices(Map serviceNameAndAttrs) throws AMException, SSOException
Deprecated.Assign services to the entity (user/group/organization/organization unit). Also sets the attributes as provided in the mapserviceNameAndAttrs.serviceNameAndAttrsis a map of keys which are service names and values which are attribute-value maps. Attribute values are validated against the respective service schemas before being set. Any required attributes (as defined in the service schema) not provided in the attribute Map, will be included and set to default values (picked up from the service schema). Only services which have been registered with the parent organization of the entity (the organization itself, in case the entity is an organization) will be assigned to the entity. So before assigning a service to an entity,registerService()should be used on the parent organization.- Parameters:
serviceNameAndAttrs- Map of Service name with Map of Attribute-Value pairs- Throws:
AMException- if an error is encounters when trying to access/retrieve data from the data storeSSOException- if the token is no longer valid- See Also:
AMOrganization.registerService(java.lang.String, boolean, boolean)
-
modifyService
void modifyService(String serviceName, Map attrMap) throws AMException, SSOException
Deprecated.Modify the service attributes of a service assigned to a entity (user/group/organization/organizational unit). It replaces existing service attribute values with the ones provided. If new attribute values are provided, those are set too. Values of the attribute are validated against the service schema. Before the values are replaced in the entry, theServiceCallbackclasses, if any, are instantiated and thevalidateAttribute()method is called.- Parameters:
serviceName- Name of the service which has to be modifiedattrMap- Map of attribute names and set of attribute values.- Throws:
AMException- if an error occurs during validation or storingSSOException- if the single sign on token is no longer valid.
-
setServiceStatus
void setServiceStatus(String serviceName, String status) throws AMException, SSOException
Deprecated.Set the status of the service for this entity (User/Organization /Group/Organizational Unit). The valid values for the status attribute are defined in the SMS DTD. Before the status attribute is set, it is verified to see if the service is first assigned to the user or not, and that the value for the status is valid per the DTD.- Parameters:
serviceName- Name of service whose status attribute has to be changedstatus- One of the status values as defined in the service schema- Throws:
AMException- if a data store exception is encountered.SSOException- if the single sign on token is no longer valid.
-
getServiceStatus
String getServiceStatus(String serviceName) throws AMException, SSOException
Deprecated.Get the status of the service for this entity (user/group/organization/ organizational unit). Returns null, if service is not assigned to the entity.- Parameters:
serviceName- Name of service- Returns:
- status Value of the status attribute
- Throws:
AMException- if a data store exception is encounteredSSOException- if single sign on token is no longer valid.
-
unassignServices
void unassignServices(Set serviceNames) throws AMException, SSOException
Deprecated.Unassigns services from the user/group/organization/ organizational unit.- Parameters:
serviceNames- Set of service names- Throws:
AMException- if there is an internal error in the access management data store.SSOException- if the single sign on token is no longer valid
-
getAssignedServices
Set getAssignedServices() throws AMException, SSOException
Deprecated.Returns all service names that are assigned to the user/group/organization/organizational unit.- Returns:
- The Set of service names that are assigned to the user.
- Throws:
AMException- if there is an internal error in the access management data store.SSOException- if the single sign on token is no longer valid
-
purge
void purge(boolean recursive, int graceperiod) throws AMException, SSOExceptionDeprecated.This method will physically delete the entry from the data store. This method will override the soft-delete option, which the methoddelete()will not. There is a big PERFORMANCE hit if this method is used to delete a large Organization in the recursive mode.- Parameters:
recursive- If true, then recursively delete the whole subtree.graceperiod- If set to an integer greater than -1, it will verify if the object was last modified at least that many days ago before physically deleting it. Pre/PostCallbackplugins as registered in the Administration Service, will be called upon object deletion. If any of thepre-callbackclasses throw an exception, then the operation is aborted.- Throws:
AMException- if there is an internal error in the access management data store.SSOException- if the single sign on token is no longer valid- See Also:
delete()
-
-