Package com.sun.identity.common.admin
Class AdminInterfaceUtils
- java.lang.Object
-
- com.sun.identity.common.admin.AdminInterfaceUtils
-
- All Implemented Interfaces:
ServiceListener
public class AdminInterfaceUtils extends Object implements ServiceListener
AdminInterfaceUtilsprovides a set common utility methods to administration console and command line tool.
-
-
Field Summary
-
Fields inherited from interface com.sun.identity.sm.ServiceListener
ADDED, MODIFIED, REMOVED
-
-
Constructor Summary
Constructors Constructor Description AdminInterfaceUtils()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static StringdefaultAgentContainerName()Returns the default agent container name.static StringdefaultGCCreateDuringOrgConfig()Returns the default group container name created when an organization is created in OpenAM.static StringdefaultGroupContainerName()Returns the default group container name.static StringdefaultHelpDeskAdminRoleCreateDuringOrgConfig()Returns the default help desk admin role name created when an organization is created in OpenAM.static StringdefaultOrgAdminRoleCreateDuringOrgConfig()Returns the default org admin role name created when an organization is created in OpenAM.static StringdefaultPCCreateDuringOrgConfig()Returns the default people container name created when an organization is created in OpenAM.static StringdefaultPeopleContainerName()Returns the default people container name.static StringdefaultPolicyAdminRoleCreateDuringOrgConfig()Returns the default policy admin role name created when an organization is created in OpenAM.static AMObjectgetAMObject(Debug debug, String dn, AMStoreConnection storeConn)Returns theAMObjectof a given DN and a store connection.static StringgetNamingAttribute(int object, Debug debug)Returns the naming attribute used the specified object.voidglobalConfigChanged(String serviceName, String version, String groupName, String serviceComponent, int type)This method will be invoked when a service's global configuration data has been changed.static booleaninOrganizationalUnit(Debug debug, AMStoreConnection storeConn, AMObject obj)Returns true if an object is a descendent of an organizational unit.voidorganizationConfigChanged(String serviceName, String version, String orgName, String groupName, String serviceComponent, int type)This method will be invoked when a service's organization configuration data has been changed.voidschemaChanged(String serviceName, String version)This method will be invoked when a service's schema has been changed.
-
-
-
Method Detail
-
getAMObject
public static AMObject getAMObject(Debug debug, String dn, AMStoreConnection storeConn) throws AMException, SSOException
Returns theAMObjectof a given DN and a store connection.- Parameters:
debug- instancedn- of the object as a StringstoreConn- store connection- Returns:
AMObject- Throws:
AMException- ifAMSDKis unable to getAMObjectfordnSSOException- if session expires.
-
inOrganizationalUnit
public static boolean inOrganizationalUnit(Debug debug, AMStoreConnection storeConn, AMObject obj)
Returns true if an object is a descendent of an organizational unit.- Parameters:
debug- instancestoreConn- Store Connection object.obj-AMObjectto be inspected.- Returns:
- true if
objis a descendent of an organizational unit.
-
getNamingAttribute
public static String getNamingAttribute(int object, Debug debug)
Returns the naming attribute used the specified object. If this naming attribute cannot be determined for the object, empty string will be returned.- Parameters:
object- type of object.debug- instance for writing warning message.- Returns:
- naming attribute for the object.
-
defaultPeopleContainerName
public static String defaultPeopleContainerName()
Returns the default people container name.- Returns:
- default people container name
-
defaultGroupContainerName
public static String defaultGroupContainerName()
Returns the default group container name.- Returns:
- default group container name
-
defaultAgentContainerName
public static String defaultAgentContainerName()
Returns the default agent container name.- Returns:
- default agent container name
-
defaultPCCreateDuringOrgConfig
public static String defaultPCCreateDuringOrgConfig()
Returns the default people container name created when an organization is created in OpenAM. This may not be the one which the user sees as his/her default container through OpenAM console.- Returns:
- Returns the default people container name created when an organization is created in OpenAM. This may not be the one which the user sees as his/her default container through OpenAM console.
-
defaultGCCreateDuringOrgConfig
public static String defaultGCCreateDuringOrgConfig()
Returns the default group container name created when an organization is created in OpenAM. This may not be the one which the user sees as his/her default container through the OpenAM console.- Returns:
- Returns the default group container name created when an organization is created in OpenAM. This may not be the one which the user sees as his/her default container through the OpenAM console.
-
defaultOrgAdminRoleCreateDuringOrgConfig
public static String defaultOrgAdminRoleCreateDuringOrgConfig()
Returns the default org admin role name created when an organization is created in OpenAM.- Returns:
- Returns the default org admin role name created when an organization is created in OpenAM.
-
defaultHelpDeskAdminRoleCreateDuringOrgConfig
public static String defaultHelpDeskAdminRoleCreateDuringOrgConfig()
Returns the default help desk admin role name created when an organization is created in OpenAM.- Returns:
- Returns the default help desk admin role name created when an organization is created in OpenAM.
-
defaultPolicyAdminRoleCreateDuringOrgConfig
public static String defaultPolicyAdminRoleCreateDuringOrgConfig()
Returns the default policy admin role name created when an organization is created in OpenAM.- Returns:
- Returns the default policy admin role name created when an organization is created in OpenAM.
-
schemaChanged
public void schemaChanged(String serviceName, String version)
Description copied from interface:ServiceListenerThis method will be invoked when a service's schema has been changed.- Specified by:
schemaChangedin interfaceServiceListener- Parameters:
serviceName- name of the serviceversion- version of the service
-
globalConfigChanged
public void globalConfigChanged(String serviceName, String version, String groupName, String serviceComponent, int type)
Description copied from interface:ServiceListenerThis method will be invoked when a service's global configuration data has been changed. The parametergroupNamedenote the name of the configuration grouping (e.g. default) andserviceComponentdenotes the service's sub-component that changed (e.g./NamedPolicy,/Templates).- Specified by:
globalConfigChangedin interfaceServiceListener- Parameters:
serviceName- name of the service.version- version of the service.groupName- name of the configuration grouping.serviceComponent- name of the service components that changed.type- change type, i.e., ADDED, REMOVED or MODIFIED.
-
organizationConfigChanged
public void organizationConfigChanged(String serviceName, String version, String orgName, String groupName, String serviceComponent, int type)
Description copied from interface:ServiceListenerThis method will be invoked when a service's organization configuration data has been changed. The parametersorgName,groupNameandserviceComponentdenotes the organization name, configuration grouping name and service's sub-component that are changed respectively.- Specified by:
organizationConfigChangedin interfaceServiceListener- Parameters:
serviceName- name of the serviceversion- version of the serviceorgName- organization name as DNgroupName- name of the configuration groupingserviceComponent- the name of the service components that changedtype- change type, i.e., ADDED, REMOVED or MODIFIED
-
-