public class CompositeTypeImpl extends ComplexTypeImpl implements CompositeType
F_UNSTRUCT_DEFAULT, F_UNSTRUCT_FALSE, F_UNSTRUCT_TRUEEMPTY_SUPERTYPES, F_NOTNULL, F_READONLY| Constructor and Description |
|---|
CompositeTypeImpl(CompositeType superType,
String schema,
String name,
String[] schemas) |
CompositeTypeImpl(TypeRef<? extends CompositeType> superType,
String schema,
String name,
String[] schemas) |
| Modifier and Type | Method and Description |
|---|---|
Field |
addField(QName name,
TypeRef<? extends Type> type)
Adds a field to this complex type.
|
void |
addSchema(Schema schema)
Adds a schema.
|
void |
addSchema(String schema)
Adds a schema.
|
Field |
getField(QName name)
Gets the field having the given name.
|
Field |
getField(String name)
Gets the field with the given name.
|
Collection<Field> |
getFields()
Gets all fields as a (field name, field type) map.
|
TypeRef<? extends CompositeType> |
getRef()
Gets a proxy (or reference to this type).
|
Schema |
getSchema(String name)
Gets the composite type schema given its name.
|
Schema |
getSchemaByPrefix(String prefix)
Finds the composite type schema given the schema prefix.
|
String[] |
getSchemaNames()
Gets the schema names of this type.
|
Collection<Schema> |
getSchemas()
Gets all the schemas (including inherited schemas) of this composite type.
|
boolean |
hasField(QName name)
Tests whether this type defines the given field name.
|
boolean |
hasSchema(String name)
Checks if this composite type has the given schema.
|
boolean |
hasSchemas()
Checks if this composite type has any schema defined.
|
boolean |
isComplexType()
Tests whether this type is a complex type.
|
boolean |
isCompositeType()
Tests whether this is a composite type.
|
boolean |
validate(Object object)
Tests whether the given object is of this type.
|
addField, addField, addField, canonicalXPath, convert, getFieldsCount, getNamespace, hasField, hasFields, isUnstructured, newInstance, toStringdecode, encode, getHelper, getName, getSchema, getSchemaName, getSuperType, getTypeHierarchy, isAny, isAnyType, isListType, isNotNull, isReadOnly, isSimpleType, isSuperTypeOf, setNotNull, setReadOnlyequals, getClass, hashCode, notify, notifyAll, wait, wait, waitaddField, addField, addField, getFieldsCount, getNamespace, hasField, hasFields, isUnstructureddecode, encode, getHelper, getName, getSchema, getSchemaName, getSuperType, getTypeHierarchy, isAnyType, isListType, isNotNull, isReadOnly, isSimpleType, isSuperTypeOf, newInstanceconvertpublic CompositeTypeImpl(CompositeType superType, String schema, String name, String[] schemas)
public CompositeTypeImpl(TypeRef<? extends CompositeType> superType, String schema, String name, String[] schemas)
public final boolean hasSchemas()
CompositeTypehasSchemas in interface CompositeTypepublic final void addSchema(String schema)
CompositeTypeaddSchema in interface CompositeTypeschema - the schema name to addpublic final void addSchema(Schema schema)
CompositeTypeaddSchema in interface CompositeTypeschema - the schema to addpublic final Schema getSchema(String name)
CompositeTypegetSchema in interface CompositeTypename - the schema namepublic final Schema getSchemaByPrefix(String prefix)
CompositeTypegetSchemaByPrefix in interface CompositeTypeprefix - the schema prefixpublic final boolean hasSchema(String name)
CompositeTypehasSchema in interface CompositeTypename - the schema namepublic final String[] getSchemaNames()
CompositeTypegetSchemaNames in interface CompositeTypepublic final Collection<Schema> getSchemas()
CompositeTypegetSchemas in interface CompositeTypepublic final Field addField(QName name, TypeRef<? extends Type> type)
ComplexTypeaddField in interface ComplexTypeaddField in class ComplexTypeImplname - the field nametype - the field typepublic final Field getField(String name)
ComplexTypeIf the name is non-prefixed the first matching field is returned if any is found. If the name is prefixed then the right field is returned if any is found.
getField in interface ComplexTypegetField in class ComplexTypeImplname - the field namepublic final Field getField(QName name)
ComplexTypegetField in interface ComplexTypegetField in class ComplexTypeImplname - the namepublic final boolean hasField(QName name)
ComplexTypehasField in interface ComplexTypehasField in class ComplexTypeImplname - the field namepublic final Collection<Field> getFields()
ComplexTypegetFields in interface ComplexTypegetFields in class ComplexTypeImplpublic final boolean isComplexType()
TypeisComplexType in interface TypeisComplexType in class ComplexTypeImplpublic final boolean isCompositeType()
TypeisCompositeType in interface TypeisCompositeType in class AbstractTypepublic final boolean validate(Object object)
Typevalidate in interface Typevalidate in class ComplexTypeImplobject - the object to testpublic TypeRef<? extends CompositeType> getRef()
TypegetRef in interface ComplexTypegetRef in interface CompositeTypegetRef in interface TypegetRef in class ComplexTypeImplCopyright © 2011 Nuxeo SA. All Rights Reserved.