Package com.iplanet.am.sdk.remote
Class RemoteServicesImpl
- java.lang.Object
-
- com.iplanet.am.sdk.remote.RemoteServicesImpl
-
- All Implemented Interfaces:
IDirectoryServices
- Direct Known Subclasses:
CachedRemoteServicesImpl
public class RemoteServicesImpl extends Object implements IDirectoryServices
-
-
Field Summary
Fields Modifier and Type Field Description protected static StringAM_SDK_DEBUG_FILEprotected static StringAMSR_ATTRSprotected static StringAMSR_CODEprotected static StringAMSR_COUNTprotected static StringAMSR_RESULTSprotected CallBackHelperBasecallBackHelperBaseprotected IComplianceServicescomplianceServicesImplprotected IDCTreeServicesdcTreeServicesImplprotected static Debugdebugprotected static StringIDREPO_SERVICEprotected static StringSDK_SERVICE
-
Constructor Summary
Constructors Constructor Description RemoteServicesImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddListener(SSOToken token, AMObjectListener listener, Map configMap)Add a listener object that will receive notifications when entries are changed.voidchangePassword(SSOToken token, String entryDN, String attrName, String oldPassword, String newPassword)Changes user password.protected static AMExceptionconvertException(AMRemoteException amrx)StringcreateAMTemplate(SSOToken token, String entryDN, int objectType, String serviceName, Map attributes, int priority)Create an AMTemplate (COSTemplate)voidcreateEntry(SSOToken token, String entryName, int objectType, String parentDN, Map attributes)Create an entry in the DirectorybooleandoesEntryExists(SSOToken token, String entryDN)Checks if the entry exists in the directory.StringgetAMTemplateDN(SSOToken token, String entryDN, int objectType, String serviceName, int type)Get the AMTemplate DN (COSTemplateDN)MapgetAttributes(SSOToken token, String entryDN, boolean ignoreCompliance, boolean byteValues, int profileType)Gets all attributes corresponding to the entryDN.MapgetAttributes(SSOToken token, String entryDN, int profileType)Returns a Map with attribute-values requested from the directory.MapgetAttributes(SSOToken token, String entryDN, Set attrNames, boolean ignoreCompliance, boolean byteValues, int profileType)Gets the specific attributes corresponding to the entryDN.MapgetAttributes(SSOToken token, String entryDN, Set attrNames, int profileType)Returns a Map with attribute-values requested from the directory.MapgetAttributesByteValues(SSOToken token, String entryDN, int profileType)Returns a map of attribute-values for binary attributes.MapgetAttributesByteValues(SSOToken token, String entryDN, Set attrNames, int profileType)Returns a map of attribute-values for binary attributes.SetgetAttributesForSchema(String objectclass)Returns the set of attributes (both optional and required) needed for an objectclass based on the LDAP schemaMapgetAttributesFromDS(SSOToken token, String entryDN, Set attrNames, int profileType)Returns a Map with attribute-values fetched directly from the Directory.IComplianceServicesgetComplianceServicesImpl()Returns an implementation instance of IComplianceServices.StringgetCreationTemplateName(int objectType)Get the name of the creation template to use for specified object type.MapgetDCTreeAttributes(SSOToken token, String entryDN, Set attrNames, boolean byteValues, int objectType)Gets the attributes for this entryDN from the corresponding DC Tree node.IDCTreeServicesgetDCTreeServicesImpl()Returns an implementation instance of IDCTreeServices.protected static DebuggetDebug()MapgetExternalAttributes(SSOToken token, String entryDN, Set attrNames, int profileType)Returns attributes from an external data store.String[]getGroupFilterAndScope(SSOToken token, String entryDN, int profileType)Returns an array containing the dynamic group's scope, base dn, and filter.protected static IDirectoryServicesgetInstance()SetgetMembers(SSOToken token, String entryDN, int objectType)Get members for roles, dynamic group or static groupStringgetNamingAttribute(int objectType, String orgDN)Gets the naming attribute after reading it from the corresponding creation template.StringgetObjectClass(int objectType)Returns the objectclass representing an object type.intgetObjectType(SSOToken token, String dn)Gets the type of the object given its DN.intgetObjectType(SSOToken token, String dn, Map cachedAttributes)Returns the integer type of the object represented by theDNusing the cached attributes.StringgetOrganizationDN(SSOToken token, String entryDN)Gets the Organization DN for the specified entryDN.StringgetOrgSearchFilter(String entryDN)Returns the search filter for organization.SetgetRegisteredServiceNames(SSOToken token, String entryDN)Get registered services for an organizationStringgetSearchFilterFromTemplate(int objectType, String orgDN, String searchTemplateName)Returns the search filter of a given search template.protected SOAPClientgetSOAPClient()SetgetTopLevelContainers(SSOToken token)Returns the set of top level containers that can be viewed by ths uservoidmodifyMemberShip(SSOToken token, Set members, String target, int type, int operation)Modify member ship for role or static groupvoidregisterService(SSOToken token, String orgDN, String serviceName)Register a service for an org or org unit policy to a profilevoidremoveAdminRole(SSOToken token, String dn, boolean recursive)Remove group admin rolevoidremoveEntry(SSOToken token, String entryDN, int objectType, boolean recursive, boolean softDelete)Remove an entry from the directory.StringrenameEntry(SSOToken token, int objectType, String entryDN, String newName, boolean deleteOldName)Renames an entry.Setsearch(SSOToken token, String entryDN, String searchFilter, int searchScope)Searches the DirectoryAMSearchResultssearch(SSOToken token, String entryDN, String searchFilter, SearchControl searchControl, String[] attrNames)Search the DirectoryvoidsetAttributes(SSOToken token, String entryDN, int objectType, Map stringAttributes, Map byteAttributes, boolean isAdd)Method Set the attributes of an entry.voidsetGroupFilter(SSOToken token, String entryDN, String filter)Sets the filter for a dynamic group in the datastore.voidunRegisterService(SSOToken token, String entryDN, int objectType, String serviceName, int type)Un register service for a AMro profile.voidupdateUserAttribute(SSOToken token, Set members, String staticGroupDN, boolean toAdd)Adds or remove static group DN to or from member attribute 'iplanet-am-static-group-dn'StringverifyAndGetOrgDN(SSOToken token, String entryDN, String childDN)Gets the Organization DN for the specified entryDN.
-
-
-
Field Detail
-
AM_SDK_DEBUG_FILE
protected static final String AM_SDK_DEBUG_FILE
- See Also:
- Constant Field Values
-
SDK_SERVICE
protected static final String SDK_SERVICE
- See Also:
- Constant Field Values
-
IDREPO_SERVICE
protected static final String IDREPO_SERVICE
- See Also:
- Constant Field Values
-
AMSR_COUNT
protected static final String AMSR_COUNT
- See Also:
- Constant Field Values
-
AMSR_RESULTS
protected static final String AMSR_RESULTS
- See Also:
- Constant Field Values
-
AMSR_CODE
protected static final String AMSR_CODE
- See Also:
- Constant Field Values
-
AMSR_ATTRS
protected static final String AMSR_ATTRS
- See Also:
- Constant Field Values
-
debug
protected static Debug debug
-
dcTreeServicesImpl
protected IDCTreeServices dcTreeServicesImpl
-
complianceServicesImpl
protected IComplianceServices complianceServicesImpl
-
callBackHelperBase
protected CallBackHelperBase callBackHelperBase
-
-
Method Detail
-
getDebug
protected static Debug getDebug()
-
getSOAPClient
protected SOAPClient getSOAPClient()
-
getInstance
protected static IDirectoryServices getInstance()
-
getDCTreeServicesImpl
public IDCTreeServices getDCTreeServicesImpl()
Description copied from interface:IDirectoryServicesReturns an implementation instance of IDCTreeServices.- Specified by:
getDCTreeServicesImplin interfaceIDirectoryServices- Returns:
- instance of IDCTreeServices.
-
getComplianceServicesImpl
public IComplianceServices getComplianceServicesImpl()
Description copied from interface:IDirectoryServicesReturns an implementation instance of IComplianceServices.- Specified by:
getComplianceServicesImplin interfaceIDirectoryServices- Returns:
- instance of IComplianceServices.
-
doesEntryExists
public boolean doesEntryExists(SSOToken token, String entryDN)
Checks if the entry exists in the directory.- Specified by:
doesEntryExistsin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- The DN of the entry that needs to be checked- Returns:
- true if the entryDN exists in the directory, false otherwise
-
getObjectType
public int getObjectType(SSOToken token, String dn) throws AMException, SSOException
Gets the type of the object given its DN.- Specified by:
getObjectTypein interfaceIDirectoryServices- Parameters:
token- token a valid SSOTokendn- DN of the object whose type is to be known.- Returns:
- Integer type of the entry.
- Throws:
AMException- if the data store is unavailable or if the object type is unknownSSOException- if ssoToken is invalid or expired.
-
getObjectType
public int getObjectType(SSOToken token, String dn, Map cachedAttributes) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns the integer type of the object represented by theDNusing the cached attributes.- Specified by:
getObjectTypein interfaceIDirectoryServices- Parameters:
token- User's single sign on tokendn-DNof the entry.cachedAttributes- cached attributes that can be used to determine the object type- Returns:
- Integer type of the entry.
- Throws:
AMException- If entry is not a supported type or if unable to access the datastore.SSOException- If user's single sign on token is invalid.
-
getDCTreeAttributes
public Map getDCTreeAttributes(SSOToken token, String entryDN, Set attrNames, boolean byteValues, int objectType) throws AMException, SSOException
Gets the attributes for this entryDN from the corresponding DC Tree node. The attributes are fetched only for Organization entries in DC tree mode.- Specified by:
getDCTreeAttributesin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- dn of the entryattrNames- attributes namebyteValues-trueif in bytesobjectType- the object type of entryDN.- Returns:
- an AttrSet of values or null if not found
- Throws:
AMException- if error encountered in fetching the DC node attributes.SSOException- If user's single sign on token is invalid.
-
getAttributes
public Map getAttributes(SSOToken token, String entryDN, int profileType) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns a Map with attribute-values requested from the directory.- Specified by:
getAttributesin interfaceIDirectoryServices- Parameters:
token- User's single sign on tokenentryDN-DNof the entry.profileType- Integer representing type of the object.- Returns:
- Map of attribute-values.
- Throws:
AMException- If unable to access datastoreSSOException- If user's single sign on token is invalid.
-
getAttributes
public Map getAttributes(SSOToken token, String entryDN, Set attrNames, int profileType) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns a Map with attribute-values requested from the directory.- Specified by:
getAttributesin interfaceIDirectoryServices- Parameters:
token- User's single sign on tokenentryDN-DNof the entry.attrNames- Set of attributes to be read.profileType- Integer representing type of the object.- Returns:
- Map of attribute-values.
- Throws:
AMException- If unable to access datastoreSSOException- If user's single sign on token is invalid.
-
getAttributesFromDS
public Map getAttributesFromDS(SSOToken token, String entryDN, Set attrNames, int profileType) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns a Map with attribute-values fetched directly from the Directory. This API will avoid caching the attributes.- Specified by:
getAttributesFromDSin interfaceIDirectoryServices- Parameters:
token- User's single sign on tokenentryDN-DNof the entry.attrNames- Set of attributes to be read.profileType- Integer representing type of the object.- Returns:
- Map of attribute-values.
- Throws:
AMException- If unable to access datastoreSSOException- If user's single sign on token is invalid.
-
getAttributesByteValues
public Map getAttributesByteValues(SSOToken token, String entryDN, int profileType) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns a map of attribute-values for binary attributes.- Specified by:
getAttributesByteValuesin interfaceIDirectoryServices- Parameters:
token- User's single sign on tokenentryDN-DNof the entry.profileType- Integer representing type of the object.- Returns:
- Map of attribute-values.
- Throws:
AMException- If unable to access datastoreSSOException- If user's single sign on token is invalid.
-
getAttributesByteValues
public Map getAttributesByteValues(SSOToken token, String entryDN, Set attrNames, int profileType) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns a map of attribute-values for binary attributes.- Specified by:
getAttributesByteValuesin interfaceIDirectoryServices- Parameters:
token- User's single sign on tokenentryDN-DNof the entry.attrNames- Names of the attributes to be read.profileType- Integer representing type of the object.- Returns:
- Map of attribute-values.
- Throws:
AMException- If unable to access datastoreSSOException- If user's single sign on token is invalid.
-
getAttributes
public Map getAttributes(SSOToken token, String entryDN, boolean ignoreCompliance, boolean byteValues, int profileType) throws AMException, SSOException
Gets all attributes corresponding to the entryDN. This method obtains the DC Tree node attributes and also performs compliance related verification checks in compliance mode. Note: In compliance mode you can skip the compliance checks by setting ignoreCompliance to "false".- Specified by:
getAttributesin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- the DN of the entry whose attributes need to retrievedignoreCompliance- a boolean value specificying if compliance related entries need to ignored or not. Ignored if true.byteValues- Return binary attributes, if true.profileType- Integer representing type of the object.- Returns:
- a Map containing attribute names as keys and Set of values corresponding to each key.
- Throws:
AMException- if an error is encountered in fetching the attributesSSOException- If user's single sign on token is invalid.
-
getAttributes
public Map getAttributes(SSOToken token, String entryDN, Set attrNames, boolean ignoreCompliance, boolean byteValues, int profileType) throws AMException, SSOException
Gets the specific attributes corresponding to the entryDN. This method obtains the DC Tree node attributes and also performs compliance related verification checks in compliance mode. Note: In compliance mode you can skip the compliance checks by setting ignoreCompliance to "false".- Specified by:
getAttributesin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- the DN of the entry whose attributes need to retrievedattrNames- a Set of names of the attributes that need to be retrieved. The attrNames should not be null.ignoreCompliance- a boolean value specificying if compliance related entries need to ignored or not. Ignored if true.byteValues- Return binary attributes, if true.profileType- Integer representing type of the object.- Returns:
- a Map containing attribute names as keys and Set of values corresponding to each key.
- Throws:
AMException- if an error is encountered in fetching the attributesSSOException- If user's single sign on token is invalid.
-
getOrgSearchFilter
public String getOrgSearchFilter(String entryDN)
Description copied from interface:IDirectoryServicesReturns the search filter for organization.- Specified by:
getOrgSearchFilterin interfaceIDirectoryServices- Parameters:
entryDN-DNof the organization.- Returns:
- Search filter.
-
getOrganizationDN
public String getOrganizationDN(SSOToken token, String entryDN) throws AMException
Gets the Organization DN for the specified entryDN. If the entry itself is an org, then same DN is returned.NOTE: This method will involve serveral directory searches, hence be cautious of Performance hit
- Specified by:
getOrganizationDNin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- the entry whose parent Organization is to be obtained- Returns:
- the DN String of the parent Organization
- Throws:
AMException- if an error occured while obtaining the parent Organization
-
verifyAndGetOrgDN
public String verifyAndGetOrgDN(SSOToken token, String entryDN, String childDN) throws AMException
Gets the Organization DN for the specified entryDN. If the entry itself is an org, then same DN is returned.- Specified by:
verifyAndGetOrgDNin interfaceIDirectoryServices- Parameters:
token- a valid SSOTokenentryDN- the entry whose parent Organization is to be obtainedchildDN- the immediate entry whose parent Organization is to be obtained- Returns:
- the DN String of the parent Organization
- Throws:
AMException- if an error occured while obtaining the parent Organization
-
getExternalAttributes
public Map getExternalAttributes(SSOToken token, String entryDN, Set attrNames, int profileType) throws AMException
Returns attributes from an external data store.- Specified by:
getExternalAttributesin interfaceIDirectoryServices- Parameters:
token- Single sign on token of userentryDN- DN of the entry user is trying to readattrNames- Set of attributes to be readprofileType- Integer determining the type of profile being read- Returns:
- A Map of attribute-value pairs
- Throws:
AMException- if an error occurs when trying to read external datastore
-
updateUserAttribute
public void updateUserAttribute(SSOToken token, Set members, String staticGroupDN, boolean toAdd) throws AMException
Adds or remove static group DN to or from member attribute 'iplanet-am-static-group-dn'- Specified by:
updateUserAttributein interfaceIDirectoryServices- Parameters:
token- SSOTokenmembers- set of user DN'sstaticGroupDN- DN of the static grouptoAdd- true to add, false to remove- Throws:
AMException- if there is an internal problem with AM Store.
-
createEntry
public void createEntry(SSOToken token, String entryName, int objectType, String parentDN, Map attributes) throws AMEntryExistsException, AMException, SSOException
Create an entry in the Directory- Specified by:
createEntryin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryName- name of the entry (naming value), e.g. "sun.com", "manager"objectType- Profile Type, ORGANIZATION, AMObject.ROLE, AMObject.USER, etc.parentDN- the parent DNattributes- the initial attribute set for creation- Throws:
AMEntryExistsExceptionAMExceptionSSOException
-
removeEntry
public void removeEntry(SSOToken token, String entryDN, int objectType, boolean recursive, boolean softDelete) throws AMException, SSOException
Remove an entry from the directory.- Specified by:
removeEntryin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- dn of the profile to be removedobjectType- profile typerecursive- if true, remove all sub entries & the objectsoftDelete- Used to let pre/post callback plugins know that this delete is either a soft delete (marked for deletion) or a purge/hard delete itself, otherwise, remove the object only- Throws:
AMExceptionSSOException
-
removeAdminRole
public void removeAdminRole(SSOToken token, String dn, boolean recursive) throws SSOException, AMException
Remove group admin role- Specified by:
removeAdminRolein interfaceIDirectoryServices- Parameters:
token- SSOToken of the callerdn- group DNrecursive- true to delete all admin roles for all sub groups or sub people container- Throws:
SSOExceptionAMException
-
search
public Set search(SSOToken token, String entryDN, String searchFilter, int searchScope) throws AMException
Searches the Directory- Specified by:
searchin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the entry to start the search withsearchFilter- search filtersearchScope- search scope, BASE, ONELEVEL or SUBTREE- Returns:
- Set set of matching DNs
- Throws:
AMException
-
search
public AMSearchResults search(SSOToken token, String entryDN, String searchFilter, SearchControl searchControl, String[] attrNames) throws AMException
Search the Directory- Specified by:
searchin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the entry to start the search withsearchFilter- search filtersearchControl- search control defining the VLV indexes and search scopeattrNames- attributes name- Returns:
- Set of matching DNs
- Throws:
AMException
-
getMembers
public Set getMembers(SSOToken token, String entryDN, int objectType) throws AMException
Get members for roles, dynamic group or static group- Specified by:
getMembersin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the role or groupobjectType- objectType of the target object, AMObject.ROLE or AMObject.GROUP- Returns:
- Set Member DNs
- Throws:
AMException
-
renameEntry
public String renameEntry(SSOToken token, int objectType, String entryDN, String newName, boolean deleteOldName) throws AMException
Renames an entry. Currently used for only user renaming- Specified by:
renameEntryin interfaceIDirectoryServices- Parameters:
token- the sso tokenobjectType- the type of entryentryDN- the entry DNnewName- the new name (i.e., if RDN is cn=John, the value passed should be "John"deleteOldName- if true the old name is deleted otherwise it is retained.- Returns:
- new
DNof the renamed entry - Throws:
AMException- if the operation was not successful
-
setAttributes
public void setAttributes(SSOToken token, String entryDN, int objectType, Map stringAttributes, Map byteAttributes, boolean isAdd) throws AMException, SSOException
Method Set the attributes of an entry.- Specified by:
setAttributesin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the profile whose template is to be setobjectType- profile typestringAttributes- attributes to be setbyteAttributes- attributes to be setisAdd-trueadd to existing value; otherwise replace existing value- Throws:
AMExceptionSSOException
-
changePassword
public void changePassword(SSOToken token, String entryDN, String attrName, String oldPassword, String newPassword) throws AMException, SSOException
Changes user password.- Specified by:
changePasswordin interfaceIDirectoryServices- Parameters:
token- Single sign on tokenentryDN- DN of the profile whose template is to be setattrName- password attribute nameoldPassword- old passwordnewPassword- new password- Throws:
AMException- if an error occurs when changing user passwordSSOException- If user's single sign on token is invalid.
-
getGroupFilterAndScope
public String[] getGroupFilterAndScope(SSOToken token, String entryDN, int profileType) throws SSOException, AMException
Returns an array containing the dynamic group's scope, base dn, and filter.- Specified by:
getGroupFilterAndScopein interfaceIDirectoryServices- Parameters:
token- Single sign on tokenentryDN- DN of the profile- Throws:
SSOExceptionAMException
-
setGroupFilter
public void setGroupFilter(SSOToken token, String entryDN, String filter) throws AMException, SSOException
Sets the filter for a dynamic group in the datastore.- Specified by:
setGroupFilterin interfaceIDirectoryServices- Parameters:
token-entryDN-filter-- Throws:
AMExceptionSSOException
-
modifyMemberShip
public void modifyMemberShip(SSOToken token, Set members, String target, int type, int operation) throws AMException
Modify member ship for role or static group- Specified by:
modifyMemberShipin interfaceIDirectoryServices- Parameters:
token- SSOTokenmembers- Set of member DN to be operatedtarget- DN of the target object to add the membertype- type of the target object, AMObject.ROLE or AMObject.GROUPoperation- type of operation, ADD_MEMBER or REMOVE_MEMBER- Throws:
AMException
-
getRegisteredServiceNames
public Set getRegisteredServiceNames(SSOToken token, String entryDN) throws AMException
Get registered services for an organization- Specified by:
getRegisteredServiceNamesin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the org- Returns:
- Set set of service names
- Throws:
AMException
-
registerService
public void registerService(SSOToken token, String orgDN, String serviceName) throws AMException, SSOException
Register a service for an org or org unit policy to a profile- Specified by:
registerServicein interfaceIDirectoryServices- Parameters:
token- tokenorgDN- DN of the orgserviceName- Service Name- Throws:
AMExceptionSSOException
-
unRegisterService
public void unRegisterService(SSOToken token, String entryDN, int objectType, String serviceName, int type) throws AMException
Un register service for a AMro profile.- Specified by:
unRegisterServicein interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the profile whose service is to be removedobjectType- profile typeserviceName- Service Nametype- Template type- Throws:
AMException
-
getAMTemplateDN
public String getAMTemplateDN(SSOToken token, String entryDN, int objectType, String serviceName, int type) throws AMException
Get the AMTemplate DN (COSTemplateDN)- Specified by:
getAMTemplateDNin interfaceIDirectoryServices- Parameters:
token- SSOTokenentryDN- DN of the profile whose template is to be setserviceName- Service Nametype- the template type, AMTemplate.DYNAMIC_TEMPLATE- Returns:
- String DN of the AMTemplate
- Throws:
AMException
-
createAMTemplate
public String createAMTemplate(SSOToken token, String entryDN, int objectType, String serviceName, Map attributes, int priority) throws AMException
Create an AMTemplate (COSTemplate)- Specified by:
createAMTemplatein interfaceIDirectoryServices- Parameters:
token- tokenentryDN- DN of the profile whose template is to be setobjectType- object typeserviceName- Service Nameattributes- attributes to be setpriority- template priority- Returns:
- String DN of the newly created template
- Throws:
AMException
-
getNamingAttribute
public String getNamingAttribute(int objectType, String orgDN)
Gets the naming attribute after reading it from the corresponding creation template. If not found, a default value will be used- Specified by:
getNamingAttributein interfaceIDirectoryServices- Parameters:
objectType- the type of object of interest.orgDN- the organization dn the object belongs to.- Returns:
- the naming attribute for the object.
-
getCreationTemplateName
public String getCreationTemplateName(int objectType)
Get the name of the creation template to use for specified object type.- Specified by:
getCreationTemplateNamein interfaceIDirectoryServices- Parameters:
objectType- Integere representing object type- Returns:
- Name of creation template
-
getObjectClass
public String getObjectClass(int objectType)
Description copied from interface:IDirectoryServicesReturns the objectclass representing an object type.- Specified by:
getObjectClassin interfaceIDirectoryServices- Parameters:
objectType- the type of object of interest.- Returns:
- the objectclass for the representing the object type.
-
getAttributesForSchema
public Set getAttributesForSchema(String objectclass)
Returns the set of attributes (both optional and required) needed for an objectclass based on the LDAP schema- Specified by:
getAttributesForSchemain interfaceIDirectoryServices- Parameters:
objectclass-- Returns:
- Set of the attributes for the object class
-
getSearchFilterFromTemplate
public String getSearchFilterFromTemplate(int objectType, String orgDN, String searchTemplateName)
Description copied from interface:IDirectoryServicesReturns the search filter of a given search template.- Specified by:
getSearchFilterFromTemplatein interfaceIDirectoryServices- Parameters:
objectType- Integere represenintg object type.orgDN- OrganizationsearchTemplateName- Name of search template- Returns:
- Search filter
-
getTopLevelContainers
public Set getTopLevelContainers(SSOToken token) throws AMException, SSOException
Description copied from interface:IDirectoryServicesReturns the set of top level containers that can be viewed by ths user- Specified by:
getTopLevelContainersin interfaceIDirectoryServices- Parameters:
token- User's single sign on token.- Returns:
- The top level containers this user manages based on its' administrative roles (if any)
- Throws:
AMException- if a datastore access failsSSOException- if user's single sign on token is invalid.
-
convertException
protected static AMException convertException(AMRemoteException amrx)
-
addListener
public void addListener(SSOToken token, AMObjectListener listener, Map configMap) throws AMEventManagerException
Description copied from interface:IDirectoryServicesAdd a listener object that will receive notifications when entries are changed.- Specified by:
addListenerin interfaceIDirectoryServices- Parameters:
token- SSOToken of the user adding the listnerlistener- listener object that will be called when entries are changed- Throws:
AMEventManagerException- if a error occurs during adding listener object
-
-