Class FrameworkUtil
- java.lang.Object
-
- org.identityconnectors.framework.common.FrameworkUtil
-
public final class FrameworkUtil extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.Set<java.lang.Class<? extends APIOperation>>
allAPIOperations()
Return all the knownAPIOperation
s.static java.util.Set<java.lang.Class<? extends SPIOperation>>
allSPIOperations()
Return all the knownSPIOperation
s.static void
checkAttributeType(java.lang.Class<?> clazz)
Determines if the class is a supported attribute type.static void
checkAttributeValue(java.lang.Object value)
Determines if the class of the object is a supported attribute type.static void
checkAttributeValue(java.lang.String name, java.lang.Object value)
Determines if the class of the object is a supported attribute type.static void
checkOperationOptionType(java.lang.Class<?> clazz)
Determines if the class is a supported type for an OperationOption.static void
checkOperationOptionValue(java.lang.Object value)
Determines if the class of the object is a supported attribute type.static java.util.Set<java.lang.Class<? extends java.lang.Object>>
getAllSupportedAttributeTypes()
static java.util.Set<java.lang.Class<? extends java.lang.Object>>
getAllSupportedConfigTypes()
static java.util.Set<java.lang.Class<? extends APIOperation>>
getDefaultSupportedOperations(java.lang.Class<? extends Connector> connector)
Determines the default set of operations that aConnector
supports.static Version
getFrameworkVersion()
Returns the version of the framework.static Uid
getUidIfGetOperation(Filter filter)
static java.util.Set<java.lang.Class<? extends APIOperation>>
getUnconditionallySupportedOperations()
Returns the set of operations that are always supported.static boolean
isSupportedAttributeType(java.lang.Class<?> clazz)
Determines if the class is a supported attribute type.static boolean
isSupportedConfigurationType(java.lang.Class<?> clazz)
Determines if the class is a supported configuration type.static java.util.Set<java.lang.Class<? extends APIOperation>>
spi2apis(java.lang.Class<? extends SPIOperation> spi)
Converts aSPIOperation
to an set ofAPIOperation
.
-
-
-
Method Detail
-
spi2apis
public static java.util.Set<java.lang.Class<? extends APIOperation>> spi2apis(java.lang.Class<? extends SPIOperation> spi)
Converts aSPIOperation
to an set ofAPIOperation
.
-
allSPIOperations
public static java.util.Set<java.lang.Class<? extends SPIOperation>> allSPIOperations()
Return all the knownSPIOperation
s.
-
allAPIOperations
public static java.util.Set<java.lang.Class<? extends APIOperation>> allAPIOperations()
Return all the knownAPIOperation
s.
-
getDefaultSupportedOperations
public static java.util.Set<java.lang.Class<? extends APIOperation>> getDefaultSupportedOperations(java.lang.Class<? extends Connector> connector)
Determines the default set of operations that aConnector
supports.
-
getUnconditionallySupportedOperations
public static java.util.Set<java.lang.Class<? extends APIOperation>> getUnconditionallySupportedOperations()
Returns the set of operations that are always supported.- Returns:
- the set of operations that are always supported
-
getAllSupportedConfigTypes
public static java.util.Set<java.lang.Class<? extends java.lang.Object>> getAllSupportedConfigTypes()
-
isSupportedConfigurationType
public static boolean isSupportedConfigurationType(java.lang.Class<?> clazz)
Determines if the class is a supported configuration type.- Parameters:
clazz
- the type to check against the list of supported types.- Returns:
- true if the type is in the list otherwise false.
-
getAllSupportedAttributeTypes
public static java.util.Set<java.lang.Class<? extends java.lang.Object>> getAllSupportedAttributeTypes()
-
isSupportedAttributeType
public static boolean isSupportedAttributeType(java.lang.Class<?> clazz)
Determines if the class is a supported attribute type.- Parameters:
clazz
- the type to check against a supported list of types.- Returns:
- true if the type is on the supported list otherwise false.
-
checkAttributeType
public static void checkAttributeType(java.lang.Class<?> clazz)
Determines if the class is a supported attribute type. If not it throws anIllegalArgumentException
.- String.class
- long.class
- Long.class
- char.class
- Character.class
- double.class
- Double.class
- float.class
- Float.class
- int.class
- Integer.class
- boolean.class
- Boolean.class
- byte.class
- Byte.class
- byte[].class
- BigDecimal.class
- BigInteger.class
- Map.class
- Parameters:
clazz
- type to check against the support list of types.- Throws:
java.lang.IllegalArgumentException
- if the type is not on the supported list.
-
checkAttributeValue
public static void checkAttributeValue(java.lang.Object value)
Determines if the class of the object is a supported attribute type. If not it throws anIllegalArgumentException
.- Parameters:
value
- The value to check or null.- Throws:
java.lang.IllegalArgumentException
- If the class of the object is a supported attribute type.
-
checkAttributeValue
public static void checkAttributeValue(java.lang.String name, java.lang.Object value)
Determines if the class of the object is a supported attribute type. If not it throws anIllegalArgumentException
.- Parameters:
name
- The name of the attribute to checkvalue
- The value to check or null.- Throws:
java.lang.IllegalArgumentException
- If the class of the object is a supported attribute type.
-
checkOperationOptionType
public static void checkOperationOptionType(java.lang.Class<?> clazz)
Determines if the class is a supported type for an OperationOption. If not it throws anIllegalArgumentException
.- Parameters:
clazz
- type to check against the support list of types.- Throws:
java.lang.IllegalArgumentException
- if the type is not on the supported list.
-
checkOperationOptionValue
public static void checkOperationOptionValue(java.lang.Object value)
Determines if the class of the object is a supported attribute type. If not it throws anIllegalArgumentException
.- Parameters:
value
- The value to check or null.- Throws:
java.lang.IllegalArgumentException
- if the class of the object is a supported attribute type
-
getUidIfGetOperation
public static Uid getUidIfGetOperation(Filter filter)
- Parameters:
filter
- the query parameter ofSearchOp.executeQuery(org.identityconnectors.framework.common.objects.ObjectClass, Object, org.identityconnectors.framework.common.objects.ResultsHandler, org.identityconnectors.framework.common.objects.OperationOptions)
- Returns:
null
if invoked fromSearchApiOp
orUid
value if invokedGetApiOp
- Since:
- 1.5
-
getFrameworkVersion
public static Version getFrameworkVersion()
Returns the version of the framework.- Returns:
- the framework version; never null.
-
-