Package org.apache.xmlbeans.impl.schema
Class BuiltinSchemaTypeSystem
java.lang.Object
org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase
org.apache.xmlbeans.impl.schema.BuiltinSchemaTypeSystem
- All Implemented Interfaces:
SchemaTypeLoader
,SchemaTypeSystem
public class BuiltinSchemaTypeSystem extends SchemaTypeLoaderBase implements SchemaTypeSystem
-
Field Summary
-
Method Summary
Modifier and Type Method Description SchemaAnnotation[]
annotations()
Returns the top-level annotationsSchemaAttributeGroup[]
attributeGroups()
Returns the attribute groups defined in this loader.SchemaType[]
attributeTypes()
Returns the attribute types defined in this loader.SchemaType[]
documentTypes()
Returns the document types defined in this loader.void
fillInType(int btc)
Links a type.SchemaGlobalAttribute
findAttribute(QName name)
Returns the global attribute defintion with the given name, or null if none.SchemaAttributeGroup.Ref
findAttributeGroupRef(QName name)
Used for on-demand loading.SchemaGlobalAttribute.Ref
findAttributeRef(QName name)
Used for on-demand loading.SchemaType
findAttributeType(QName name)
Returns the attribute type containing the given attribute name, or null if none.SchemaType.Ref
findAttributeTypeRef(QName name)
Used for on-demand loading.SchemaType
findDocumentType(QName name)
Returns the document type rooted at the given element name, or null if none.SchemaType.Ref
findDocumentTypeRef(QName name)
Used for on-demand loading.SchemaGlobalElement
findElement(QName name)
Returns the global element defintion with the given name, or null if none.SchemaGlobalElement.Ref
findElementRef(QName name)
Used for on-demand loading.SchemaIdentityConstraint.Ref
findIdentityConstraintRef(QName name)
Used for on-demand loading.SchemaModelGroup.Ref
findModelGroupRef(QName name)
Used for on-demand loading.SchemaType
findType(QName name)
Returns the type with the given name, or null if none.SchemaType.Ref
findTypeRef(QName name)
Used for on-demand loading.static SchemaTypeSystem
get()
ClassLoader
getClassLoader()
Returns the classloader used by this loader for resolving types.String
getName()
Returns the name of this loader.static SchemaType
getNoType()
InputStream
getSourceAsStream(String sourceName)
Loads original XSD source as a stream.SchemaGlobalAttribute[]
globalAttributes()
Returns the global attributes defined in this loader.SchemaGlobalElement[]
globalElements()
Returns the global elements defined in this loader.SchemaType[]
globalTypes()
Returns the global types defined in this loader.String
handleForType(SchemaType type)
Returns the handle for the given type within this loader.boolean
isNamespaceDefined(String namespace)
True if the typeloader contains any definitions in the given namespace.SchemaModelGroup[]
modelGroups()
Returns the model groups defined in this loader.void
resolve()
Initializes a type system (resolves all handles within the type system).SchemaComponent
resolveHandle(String handle)
Locates a type, element, or attribute using the handle.void
save(Filer filer)
Saves this type system using a Filervoid
saveToDirectory(File classDir)
Saves this type to a directory.SchemaType
typeForClassname(String classname)
Finds a type for a given fully-qualified XML Bean classnameSchemaType
typeForHandle(String handle)
Locates a type, element, or attribute using the handle.Methods inherited from class org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase
compilePath, compilePath, compileQuery, compileQuery, findAttributeGroup, findModelGroup, newDomImplementation, newInstance, newXmlSaxHandler, parse, parse, parse, parse, parse, parse, parse, typeForSignature
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.xmlbeans.SchemaTypeLoader
compilePath, compileQuery, findAttributeGroup, findModelGroup, newDomImplementation, newInstance, newXmlSaxHandler, parse, parse, parse, parse, parse, parse, parse, typeForSignature
-
Field Details
-
ST_ANY_TYPE
-
ST_ANY_SIMPLE
-
ST_BOOLEAN
-
ST_BASE_64_BINARY
-
ST_HEX_BINARY
-
ST_ANY_URI
-
ST_QNAME
-
ST_NOTATION
-
ST_FLOAT
-
ST_DOUBLE
-
ST_DECIMAL
-
ST_STRING
-
ST_DURATION
-
ST_DATE_TIME
-
ST_TIME
-
ST_DATE
-
ST_G_YEAR_MONTH
-
ST_G_YEAR
-
ST_G_MONTH_DAY
-
ST_G_DAY
-
ST_G_MONTH
-
ST_INTEGER
-
ST_LONG
-
ST_INT
-
ST_SHORT
-
ST_BYTE
-
ST_NON_POSITIVE_INTEGER
-
ST_NEGATIVE_INTEGER
-
ST_NON_NEGATIVE_INTEGER
-
ST_POSITIVE_INTEGER
-
ST_UNSIGNED_LONG
-
ST_UNSIGNED_INT
-
ST_UNSIGNED_SHORT
-
ST_UNSIGNED_BYTE
-
ST_NORMALIZED_STRING
-
ST_TOKEN
-
ST_NAME
-
ST_NCNAME
-
ST_LANGUAGE
-
ST_ID
-
ST_IDREF
-
ST_IDREFS
-
ST_ENTITY
-
ST_ENTITIES
-
ST_NMTOKEN
-
ST_NMTOKENS
-
ST_NO_TYPE
-
-
Method Details
-
get
-
getName
Returns the name of this loader.- Specified by:
getName
in interfaceSchemaTypeSystem
-
isNamespaceDefined
Description copied from interface:SchemaTypeLoader
True if the typeloader contains any definitions in the given namespace.- Specified by:
isNamespaceDefined
in interfaceSchemaTypeLoader
-
findType
Description copied from interface:SchemaTypeLoader
Returns the type with the given name, or null if none.- Specified by:
findType
in interfaceSchemaTypeLoader
- Overrides:
findType
in classSchemaTypeLoaderBase
-
findDocumentType
Description copied from interface:SchemaTypeLoader
Returns the document type rooted at the given element name, or null if none.- Specified by:
findDocumentType
in interfaceSchemaTypeLoader
- Overrides:
findDocumentType
in classSchemaTypeLoaderBase
-
findAttributeType
Description copied from interface:SchemaTypeLoader
Returns the attribute type containing the given attribute name, or null if none.- Specified by:
findAttributeType
in interfaceSchemaTypeLoader
- Overrides:
findAttributeType
in classSchemaTypeLoaderBase
-
findElement
Description copied from interface:SchemaTypeLoader
Returns the global element defintion with the given name, or null if none.- Specified by:
findElement
in interfaceSchemaTypeLoader
- Overrides:
findElement
in classSchemaTypeLoaderBase
-
findAttribute
Description copied from interface:SchemaTypeLoader
Returns the global attribute defintion with the given name, or null if none.- Specified by:
findAttribute
in interfaceSchemaTypeLoader
- Overrides:
findAttribute
in classSchemaTypeLoaderBase
-
findTypeRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findTypeRef
in interfaceSchemaTypeLoader
-
findDocumentTypeRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findDocumentTypeRef
in interfaceSchemaTypeLoader
-
findAttributeTypeRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findAttributeTypeRef
in interfaceSchemaTypeLoader
-
findElementRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findElementRef
in interfaceSchemaTypeLoader
-
findAttributeRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findAttributeRef
in interfaceSchemaTypeLoader
-
findModelGroupRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findModelGroupRef
in interfaceSchemaTypeLoader
-
findAttributeGroupRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findAttributeGroupRef
in interfaceSchemaTypeLoader
-
findIdentityConstraintRef
Description copied from interface:SchemaTypeLoader
Used for on-demand loading.- Specified by:
findIdentityConstraintRef
in interfaceSchemaTypeLoader
-
typeForClassname
Description copied from interface:SchemaTypeLoader
Finds a type for a given fully-qualified XML Bean classname- Specified by:
typeForClassname
in interfaceSchemaTypeLoader
-
getSourceAsStream
Description copied from interface:SchemaTypeLoader
Loads original XSD source as a stream. SeeSchemaComponent.getSourceName()
.- Specified by:
getSourceAsStream
in interfaceSchemaTypeLoader
-
globalTypes
Returns the global types defined in this loader.- Specified by:
globalTypes
in interfaceSchemaTypeSystem
-
documentTypes
Returns the document types defined in this loader.- Specified by:
documentTypes
in interfaceSchemaTypeSystem
-
attributeTypes
Returns the attribute types defined in this loader.- Specified by:
attributeTypes
in interfaceSchemaTypeSystem
-
globalElements
Returns the global elements defined in this loader.- Specified by:
globalElements
in interfaceSchemaTypeSystem
-
globalAttributes
Returns the global attributes defined in this loader.- Specified by:
globalAttributes
in interfaceSchemaTypeSystem
-
modelGroups
Returns the model groups defined in this loader.- Specified by:
modelGroups
in interfaceSchemaTypeSystem
-
attributeGroups
Returns the attribute groups defined in this loader.- Specified by:
attributeGroups
in interfaceSchemaTypeSystem
-
annotations
Description copied from interface:SchemaTypeSystem
Returns the top-level annotations- Specified by:
annotations
in interfaceSchemaTypeSystem
-
handleForType
Returns the handle for the given type within this loader. -
getClassLoader
Returns the classloader used by this loader for resolving types.- Specified by:
getClassLoader
in interfaceSchemaTypeSystem
-
saveToDirectory
Saves this type to a directory.- Specified by:
saveToDirectory
in interfaceSchemaTypeSystem
-
save
Saves this type system using a Filer- Specified by:
save
in interfaceSchemaTypeSystem
-
resolve
public void resolve()Description copied from interface:SchemaTypeSystem
Initializes a type system (resolves all handles within the type system).- Specified by:
resolve
in interfaceSchemaTypeSystem
-
typeForHandle
Description copied from interface:SchemaTypeSystem
Locates a type, element, or attribute using the handle.- Specified by:
typeForHandle
in interfaceSchemaTypeSystem
-
resolveHandle
Description copied from interface:SchemaTypeSystem
Locates a type, element, or attribute using the handle.- Specified by:
resolveHandle
in interfaceSchemaTypeSystem
-
fillInType
public void fillInType(int btc)Links a type. -
getNoType
-