Package com.sun.identity.policy
Class ServiceTypeManager
- java.lang.Object
-
- com.sun.identity.policy.ServiceTypeManager
-
public class ServiceTypeManager extends Object
The classServiceTypeManagerprovides methods to determine the services that have policy privileges and and interfaces to instantiateServiceTypeobjects. This is a singleton class.
-
-
Constructor Summary
Constructors Constructor Description ServiceTypeManager(SSOToken token)Constructor to obtain an instance ofServiceTypeManagerusing single-sign-on tokenSSOToken.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static intgetPolicyServiceRevisionNumber()Returns service revision number of policy serviceServiceTypegetServiceType(String serviceTypeName)Returns aServiceTypeobject for the given service name.SetgetServiceTypeNames()Returns a set of service names that have policy privileges.
-
-
-
Constructor Detail
-
ServiceTypeManager
public ServiceTypeManager(SSOToken token) throws SSOException
Constructor to obtain an instance ofServiceTypeManagerusing single-sign-on tokenSSOToken. If the single-sign-on token is invalid or has expired anSSOExceptionwill be thrown.- Parameters:
token- single-sign-on token of the user- Throws:
SSOException- single-sign-on token has either expired or is invalid
-
-
Method Detail
-
getServiceTypeNames
public Set getServiceTypeNames() throws SSOException, NoPermissionException
Returns a set of service names that have policy privileges.- Returns:
- set of service type names that have policy privileges
- Throws:
SSOException- single-sign-on token has either expired or is invalidNoPermissionException- user does not have privileges to access service names
-
getServiceType
public ServiceType getServiceType(String serviceTypeName) throws SSOException, NameNotFoundException
Returns aServiceTypeobject for the given service name. If the service does not exist, the exceptionNameNotFoundExceptionis thrown.- Parameters:
serviceTypeName- name of the service- Returns:
ServiceTypeobject for the given service name- Throws:
SSOException- single-sign-on token has either expired or is invalidNameNotFoundException- service for the givenserviceTypeNamedoes not exist
-
getPolicyServiceRevisionNumber
public static int getPolicyServiceRevisionNumber() throws PolicyException, SSOException, SMSExceptionReturns service revision number of policy service- Returns:
- service revision number of policy service
- Throws:
PolicyExceptionSSOExceptionSMSException
-
-