Package org.nuxeo.ecm.core.schema.types
Class AnyType
java.lang.Object
org.nuxeo.ecm.core.schema.types.AbstractType
org.nuxeo.ecm.core.schema.types.AnyType
- All Implemented Interfaces:
Serializable
,Type
Type representing any type (for lists).
- See Also:
-
Field Summary
Fields inherited from class org.nuxeo.ecm.core.schema.types.AbstractType
constraints, EMPTY_SUPERTYPES, name, schema, superType
-
Method Summary
Modifier and TypeMethodDescriptionConverts the given value to an object compatible with the associated type.Gets the super type.Type[]
Gets the entire hierarchy of super-types.boolean
Tests whether this type is the ANY type.protected Object
boolean
Tests whether the given object is of this type.Methods inherited from class org.nuxeo.ecm.core.schema.types.AbstractType
addConstraints, decode, encode, getConstraints, getName, getObjectResolver, getSchema, getSchemaName, isAny, isComplexType, isCompositeType, isListType, isSimpleType, isSuperTypeOf, newInstance, validateConstraints
-
Field Details
-
ID
- See Also:
-
INSTANCE
-
-
Method Details
-
getSuperType
Description copied from interface:Type
Gets the super type.- Specified by:
getSuperType
in interfaceType
- Overrides:
getSuperType
in classAbstractType
- Returns:
- the super type or null if this is a primitive type
-
getTypeHierarchy
Description copied from interface:Type
Gets the entire hierarchy of super-types.The array is ordered as follows:
- the direct super type is the first element,
- the super super type is the second element,
- and so on.
The returned array is never null. An empty array is returned in the case of
ANY
type.- Specified by:
getTypeHierarchy
in interfaceType
- Overrides:
getTypeHierarchy
in classAbstractType
- Returns:
- an array containing the supertypes of this type
-
isAnyType
public boolean isAnyType()Description copied from interface:Type
Tests whether this type is the ANY type.- Specified by:
isAnyType
in interfaceType
- Overrides:
isAnyType
in classAbstractType
- Returns:
- true if it is the ANY type, false otherwise
-
validate
Description copied from interface:Type
Tests whether the given object is of this type.- Specified by:
validate
in interfaceType
- Overrides:
validate
in classAbstractType
- Parameters:
object
- the object to test- Returns:
- true if the given object if of this type, false otherwise
-
convert
Description copied from interface:Type
Converts the given value to an object compatible with the associated type.- Parameters:
object
- the value to convert- Returns:
- the converted value
-
readResolve
-