Public Member Functions | |
Schema () | |
Schema (String schemaNS) | |
Schema (String prefix, String schemaNS) | |
void | addAttribute (AttributeDecl attribute) throws SchemaException |
void | addAttributeGroup (AttributeGroupDecl attrGroup) throws SchemaException |
synchronized void | addComplexType (ComplexType complexType) throws SchemaException |
void | addElementDecl (ElementDecl elementDecl) throws SchemaException |
void | addModelGroup (ModelGroup group) throws SchemaException |
void | addRedefineSchema (RedefineSchema schema) throws SchemaException |
synchronized void | addImportedSchema (Schema schema) throws SchemaException |
synchronized void | cacheIncludedSchema (Schema schema) throws SchemaException |
void | addNamespace (String prefix, String ns) |
synchronized void | addSimpleType (SimpleType simpleType) throws SchemaException |
ComplexType | createComplexType () |
ComplexType | createComplexType (String name) |
SimpleType | createSimpleType (String name, String baseName, String derivation) |
SimpleType | createSimpleType (String name, SimpleType baseType) |
Form | getAttributeFormDefault () |
Enumeration | getAttributes () |
AttributeDecl | getAttribute (String name) |
Enumeration | getAttributeGroups () |
AttributeGroup | getAttributeGroup (String name) |
BlockList | getBlockDefault () |
String | getBuiltInTypeName (int builtInTypeCode) |
ComplexType | getComplexType (String name) |
Enumeration | getComplexTypes () |
ElementDecl | getElementDecl (String name) |
Enumeration | getElementDecls () |
Form | getElementFormDefault () |
FinalList | getFinalDefault () |
SimpleType | getSimpleType (String name) |
SimpleType | getSimpleType (String name, String namespace) |
Enumeration | getSimpleTypes () |
String | getSchemaLocation () |
ModelGroup | getModelGroup (String name) |
Enumeration | getModelGroups () |
String | getId () |
Enumeration | getImportedSchema () |
Schema | getImportedSchema (String ns) |
Enumeration | getRedefineSchema () |
RedefineSchema | getRedefineSchema (String schemaLocation) |
Schema | getCachedIncludedSchema (String schemaLocation) |
Enumeration | getCachedIncludedSchemas () |
Schema | getImportedSchema (String ns, boolean localOnly) |
final String | getNamespace (String prefix) |
Namespaces | getNamespaces () |
void | addInclude (String include) |
boolean | includeProcessed (String includeFile) |
String | getSchemaNamespace () |
String | getTargetNamespace () |
String | getVersion () |
boolean | isKnownNamespace (String namespaceURL) |
boolean | removeComplexType (ComplexType complexType) |
boolean | removeElement (ElementDecl element) |
boolean | removeAttribute (AttributeDecl attribute) |
boolean | removeGroup (ModelGroup group) |
boolean | removeAttributeGroup (AttributeGroupDecl group) |
synchronized boolean | removeCachedIncludedSchema (Schema schema) |
synchronized boolean | removeImportedSchema (Schema schema) |
boolean | removeNamespace (String prefix) |
synchronized boolean | removeRedefineSchema (RedefineSchema schema) |
boolean | removeSimpleType (SimpleType simpleType) |
void | setAttributeFormDefault (Form attributeFormDefault) |
void | setBlockDefault (BlockList block) |
void | setBlockDefault (String block) |
void | setElementFormDefault (Form elementFormDefault) |
void | setFinalDefault (FinalList finalList) |
void | setFinalDefault (String finalValues) |
void | setSchemaLocation (String schemaLocation) |
XMLType | getType (String typeName) |
void | setId (String id) |
void | setTargetNamespace (String targetNamespace) |
void | setVersion (String version) |
short | getStructureType () |
void | validate () throws ValidationException |
Static Public Attributes | |
static final String | DEFAULT_SCHEMA_NS = "http://www.w3.org/2001/XMLSchema" |
static final String | XSI_NAMESPACE = "http://www.w3.org/2001/XMLSchema-instance" |
Protected Member Functions | |
String | getNamespacePrefix (String namespace) |
Schema | getMasterSchema () |
void | setMasterSchema (Schema masterSchema) |
Static Package Functions | |
static SimpleTypesFactory | getTypeFactory () |
A class representing an XML Schema Definition. This class also contains some Factory methods for creating Top-Level structures.
org.exolab.castor.xml.schema.Schema.Schema | ( | ) |
Creates a new Schema definition
References org.exolab.castor.xml.schema.Schema.DEFAULT_SCHEMA_NS.
org.exolab.castor.xml.schema.Schema.Schema | ( | String | schemaNS | ) |
org.exolab.castor.xml.schema.Schema.Schema | ( | String | prefix, | |
String | schemaNS | |||
) |
Creates a new Schema definition
prefix | the desired namespace prefix for the schemaNS. | |
schemaNS | the namespace of the XML Schema itself. Note this is not the same as the targetNamespace. |
References org.exolab.castor.xml.schema.Schema.addNamespace(), and org.exolab.castor.xml.schema.Schema.DEFAULT_SCHEMA_NS.
void org.exolab.castor.xml.schema.Schema.addAttribute | ( | AttributeDecl | attribute | ) | throws SchemaException |
Adds the given attribute definition to this Schema definition
attribute | the AttributeDecl to add |
SchemaException | if an AttributeDecl already exisits with the same name |
References org.exolab.castor.xml.schema.Schema.getAttribute().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement().
void org.exolab.castor.xml.schema.Schema.addAttributeGroup | ( | AttributeGroupDecl | attrGroup | ) | throws SchemaException |
Adds the given attribute group definition to this Schema definition.
attrGroup | the AttributeGroupDecl to add |
SchemaException | if an AttributeGroupDecl already exisits with the same name |
References org.exolab.castor.xml.schema.Schema.getAttributeGroup(), and org.exolab.castor.xml.Namespaces.getNamespaceURI().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement().
synchronized void org.exolab.castor.xml.schema.Schema.addComplexType | ( | ComplexType | complexType | ) | throws SchemaException |
Adds the given Complextype definition to this Schema defintion
complextype | the Complextype to add to this Schema |
SchemaException | if the Complextype does not have a name or if another Complextype already exists with the same name |
References org.exolab.castor.xml.schema.Schema.getComplexType(), and org.exolab.castor.xml.schema.ComplexType.isRedefined().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement(), and org.exolab.castor.xml.schema.XMLType.setName().
void org.exolab.castor.xml.schema.Schema.addElementDecl | ( | ElementDecl | elementDecl | ) | throws SchemaException |
Adds the given Element declaration to this Schema defintion
elementDecl | the ElementDecl to add to this SchemaDef |
SchemaException | when an ElementDecl already exists with the same name as the given ElementDecl |
References org.exolab.castor.xml.schema.Schema.getElementDecl().
Referenced by org.exolab.castor.xml.dtd.Converter.convertDTDObjectToSchemaObject(), org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.endElement(), and org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement().
synchronized void org.exolab.castor.xml.schema.Schema.addImportedSchema | ( | Schema | schema | ) | throws SchemaException |
Adds the given Schema definition to this Schema definition as an imported schenma
SchemaException | if the Schema already exists |
Referenced by org.exolab.castor.xml.schema.reader.ImportUnmarshaller.ImportUnmarshaller().
void org.exolab.castor.xml.schema.Schema.addInclude | ( | String | include | ) |
Indicates that the given XML Schema file has been processed via an <xs:include>
Referenced by org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller().
void org.exolab.castor.xml.schema.Schema.addModelGroup | ( | ModelGroup | group | ) | throws SchemaException |
Adds the given Group declaration to this Schema definition
group | the Group to add to this SchemaDef |
SchemaException | when an Group already exists with the same name as the given Group |
References org.exolab.castor.xml.schema.Schema.getModelGroup(), and org.exolab.castor.xml.schema.ModelGroup.isRedefined().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement().
void org.exolab.castor.xml.schema.Schema.addNamespace | ( | String | prefix, | |
String | ns | |||
) |
Adds to the namespaces declared in this Schema
namespaces | the list of namespaces |
References org.exolab.castor.xml.Namespaces.addNamespace().
Referenced by org.exolab.castor.xml.schema.Schema.Schema(), and org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.XMLInstance2SchemaHandler().
void org.exolab.castor.xml.schema.Schema.addRedefineSchema | ( | RedefineSchema | schema | ) | throws SchemaException |
Adds the given redefinition of structures to this Schema definition. This structure is mainly used to allow the writing of an XML schema that contains redefinitions. The validation process is permissive since the method won't check that the XML Schema is already imported nor will it check that the redefined structures exist.
redefineSchema | the Group to add to this SchemaDef |
SchemaException | when an redefintion already exists with the same name as the given ElementDecl |
Referenced by org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller().
synchronized void org.exolab.castor.xml.schema.Schema.addSimpleType | ( | SimpleType | simpleType | ) | throws SchemaException |
Adds the given SimpletType definition to this Schema defintion
simpletype | the SimpleType to add to this Schema |
SchemaException | if the SimpleType does not have a name or if another SimpleType already exists with the same name |
References org.exolab.castor.xml.schema.Schema.getSimpleType(), and org.exolab.castor.xml.schema.SimpleType.isRedefined().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement(), and org.exolab.castor.xml.schema.XMLType.setName().
synchronized void org.exolab.castor.xml.schema.Schema.cacheIncludedSchema | ( | Schema | schema | ) | throws SchemaException |
Caches the given Schema definition as an included XML Schema of this Schema definition.
SchemaException | if the Schema already exists |
Referenced by org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller().
ComplexType org.exolab.castor.xml.schema.Schema.createComplexType | ( | ) |
Creates a new ComplexType using this Schema as the owning Schema document. A call to addComplexType must still be made in order to add the complexType to this Schema.
Referenced by org.exolab.castor.xml.schema.reader.ComplexTypeUnmarshaller.ComplexTypeUnmarshaller().
ComplexType org.exolab.castor.xml.schema.Schema.createComplexType | ( | String | name | ) |
Creates a new ComplexType using this Schema as the owning Schema document. A call to addComplexType must still be made in order to add the complexType to this Schema.
name | the name of the ComplexType |
SimpleType org.exolab.castor.xml.schema.Schema.createSimpleType | ( | String | name, | |
String | baseName, | |||
String | derivation | |||
) |
Creates a new SimpleType using this Schema as the owning Schema document. A call to addSimpleType must till be made in order to add the SimpleType to this Schema.
name | the name of the SimpleType | |
baseName | the name of the SimpleType's base type | |
derivation | the name of the derivation method (""/"list"/"restriction") |
References org.exolab.castor.xml.schema.SimpleTypesFactory.createUserSimpleType().
Referenced by org.exolab.castor.xml.schema.reader.SimpleTypeDefinition.createSimpleType().
SimpleType org.exolab.castor.xml.schema.Schema.createSimpleType | ( | String | name, | |
SimpleType | baseType | |||
) |
Creates a new SimpleType using this Schema as the owning Schema document. A call to addSimpleType must till be made in order to add the SimpleType to this Schema if the type is to be global.
name | the name of the SimpleType | |
baseType | the base type of the SimpleType to create |
References org.exolab.castor.xml.schema.SimpleTypesFactory.createUserSimpleType().
AttributeDecl org.exolab.castor.xml.schema.Schema.getAttribute | ( | String | name | ) |
Returns the top-level Attribute associated with the given name.
References org.exolab.castor.xml.schema.Schema.getAttribute(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.addAttribute(), org.exolab.castor.xml.schema.Schema.getAttribute(), org.exolab.castor.xml.schema.AttributeDecl.getReference(), and org.exolab.castor.xml.schema.AttributeDecl.validate().
Form org.exolab.castor.xml.schema.Schema.getAttributeFormDefault | ( | ) |
Returns the attributeFormDefault property of this Schema.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace().
AttributeGroup org.exolab.castor.xml.schema.Schema.getAttributeGroup | ( | String | name | ) |
Returns the AttributeGroup associated with the given name.
References org.exolab.castor.xml.schema.RedefineSchema.getAttributeGroup(), org.exolab.castor.xml.schema.Schema.getAttributeGroup(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasAttributeGroupRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.addAttributeGroup(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.xml.schema.Schema.getAttributeGroup(), and org.exolab.castor.xml.schema.AttributeGroupReference.resolveReference().
Enumeration org.exolab.castor.xml.schema.Schema.getAttributeGroups | ( | ) |
Returns an Enumeration of all top-level AttributeGroup declarations
References org.exolab.castor.xml.schema.RedefineSchema.enumerateAttributeGroups(), org.exolab.castor.xml.schema.Schema.getAttributeGroups(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasAttributeGroupRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.getAttributeGroups().
Enumeration org.exolab.castor.xml.schema.Schema.getAttributes | ( | ) |
Returns an Enumeration of all top-level Attribute declarations
References org.exolab.castor.xml.schema.Schema.getAttributes(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.getAttributes().
BlockList org.exolab.castor.xml.schema.Schema.getBlockDefault | ( | ) |
String org.exolab.castor.xml.schema.Schema.getBuiltInTypeName | ( | int | builtInTypeCode | ) |
Gets a built in type's name given its code.
References org.exolab.castor.xml.schema.SimpleTypesFactory.getBuiltInTypeName().
Schema org.exolab.castor.xml.schema.Schema.getCachedIncludedSchema | ( | String | schemaLocation | ) |
Returns the cached included schema with the given SchemaLocation
schemaLocation | the schemaLocation value used as a key to store the cached included XML schema |
Enumeration org.exolab.castor.xml.schema.Schema.getCachedIncludedSchemas | ( | ) |
ComplexType org.exolab.castor.xml.schema.Schema.getComplexType | ( | String | name | ) |
Returns the ComplexType of associated with the given name
References org.exolab.castor.xml.schema.RedefineSchema.getComplexType(), org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasComplexTypeRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.addComplexType(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.schema.Schema.getType(), and org.exolab.castor.xml.schema.TypeReference.resolveTypeReference().
Enumeration org.exolab.castor.xml.schema.Schema.getComplexTypes | ( | ) |
Returns an Enumeration of all top-level ComplexType declarations
References org.exolab.castor.xml.schema.RedefineSchema.enumerateComplexTypes(), org.exolab.castor.xml.schema.Schema.getComplexTypes(), org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasComplexTypeRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by com.cosylab.cdb.jdal.XSDElementTypeResolver.doesExtend(), org.exolab.castor.xml.schema.Schema.getComplexTypes(), and com.cosylab.cdb.jdal.XSDElementTypeResolver.internalGetElementTypes().
ElementDecl org.exolab.castor.xml.schema.Schema.getElementDecl | ( | String | name | ) |
Returns the ElementDecl of associated with the given name
References org.exolab.castor.xml.schema.Schema.getElementDecl(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.addElementDecl(), org.exolab.castor.xml.schema.Schema.getElementDecl(), org.exolab.castor.xml.schema.ElementDecl.getReference(), and org.exolab.castor.xml.schema.ElementDecl.validate().
Enumeration org.exolab.castor.xml.schema.Schema.getElementDecls | ( | ) |
Returns an Enumeration of all top-level element declarations
References org.exolab.castor.xml.schema.Schema.getElementDecls(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by com.cosylab.cdb.jdal.XSDElementTypeResolver.doesExtend(), org.exolab.castor.xml.schema.Schema.getElementDecls(), org.exolab.castor.xml.schema.ElementDecl.getSubstitutionGroupMembers(), and com.cosylab.cdb.jdal.XSDElementTypeResolver.internalGetElementTypes().
Form org.exolab.castor.xml.schema.Schema.getElementFormDefault | ( | ) |
Returns the elementFormDefault property of this Schema.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace().
FinalList org.exolab.castor.xml.schema.Schema.getFinalDefault | ( | ) |
String org.exolab.castor.xml.schema.Schema.getId | ( | ) |
Returns the Id for this Schema, as specified by the Id attribute, or null if no Id exists.
Enumeration org.exolab.castor.xml.schema.Schema.getImportedSchema | ( | ) |
Returns the imported schemas of this schema
Referenced by org.exolab.castor.xml.schema.Schema.getAttribute(), org.exolab.castor.xml.schema.Schema.getAttributeGroup(), org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.schema.Schema.getElementDecl(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.schema.Schema.getModelGroup(), org.exolab.castor.xml.schema.Schema.getSimpleType(), and org.exolab.castor.xml.schema.reader.ImportUnmarshaller.ImportUnmarshaller().
Schema org.exolab.castor.xml.schema.Schema.getImportedSchema | ( | String | ns | ) |
Returns the imported schema with the given namespace
ns | the namespace of the imported schema to return |
References org.exolab.castor.xml.schema.Schema.getImportedSchema().
Schema org.exolab.castor.xml.schema.Schema.getImportedSchema | ( | String | ns, | |
boolean | localOnly | |||
) |
Returns the imported schema with the given namespace
ns | the namespace of the imported schema to return | |
localOnly | a boolean that indicates only local imports should be searched. |
References org.exolab.castor.xml.schema.Schema.getImportedSchema().
Schema org.exolab.castor.xml.schema.Schema.getMasterSchema | ( | ) | [protected] |
Returns the master schema in which this instance of schema is used at runtime. This method is meant to be used at runtime.
Referenced by org.exolab.castor.xml.schema.ModelGroup.getReference(), org.exolab.castor.xml.schema.AttributeDecl.getSimpleType(), org.exolab.castor.xml.schema.ElementDecl.getType(), and org.exolab.castor.xml.schema.AttributeGroupReference.resolveReference().
ModelGroup org.exolab.castor.xml.schema.Schema.getModelGroup | ( | String | name | ) |
Returns the ModeGroup of associated with the given name
References org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.schema.RedefineSchema.getModelGroup(), org.exolab.castor.xml.schema.Schema.getModelGroup(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasGroupRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.addModelGroup(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.xml.schema.Schema.getModelGroup(), and org.exolab.castor.xml.schema.ModelGroup.getReference().
Enumeration org.exolab.castor.xml.schema.Schema.getModelGroups | ( | ) |
Returns an Enumeration of all top-level ModelGroup declarations
References org.exolab.castor.xml.schema.RedefineSchema.enumerateGroups(), org.exolab.castor.xml.schema.Schema.getModelGroups(), org.exolab.castor.xml.schema.ModelGroup.getName(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.RedefineSchema.hasGroupRedefinition(), and org.exolab.castor.xml.schema.Schema.setMasterSchema().
Referenced by org.exolab.castor.xml.schema.Schema.getModelGroups().
final String org.exolab.castor.xml.schema.Schema.getNamespace | ( | String | prefix | ) |
Returns the namespace associated with the given prefix.
References org.exolab.castor.xml.Namespaces.getNamespaceURI().
Referenced by org.exolab.castor.xml.schema.RedefineSchema.addAttributeGroup(), org.exolab.castor.xml.schema.TypeReference.resolveTypeReference(), and org.exolab.castor.xml.schema.reader.SimpleTypeUnmarshaller.SimpleTypeUnmarshaller().
String org.exolab.castor.xml.schema.Schema.getNamespacePrefix | ( | String | namespace | ) | [protected] |
Returns the namespace prefix associated with the given namespace. If more than one prefix has been associated, the first one found will be returned.
References org.exolab.castor.xml.Namespaces.getNamespacePrefix().
Referenced by org.exolab.castor.xml.schema.ElementDecl.setReference().
Namespaces org.exolab.castor.xml.schema.Schema.getNamespaces | ( | ) |
Returns the namespaces declared for this Schema
Referenced by org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.XMLInstance2SchemaHandler().
RedefineSchema org.exolab.castor.xml.schema.Schema.getRedefineSchema | ( | String | schemaLocation | ) |
Returns the redefined schema corresponding schemaLocation.
schemaLocation | the string corresponding to the schemaLocation. |
Enumeration org.exolab.castor.xml.schema.Schema.getRedefineSchema | ( | ) |
Returns an enumeration of redefined schemas.
Referenced by org.exolab.castor.xml.schema.Schema.getAttributeGroup(), org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.schema.Schema.getModelGroup(), org.exolab.castor.xml.schema.Schema.getSimpleType(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller(), org.exolab.castor.xml.schema.Schema.removeAttributeGroup(), org.exolab.castor.xml.schema.Schema.removeComplexType(), org.exolab.castor.xml.schema.Schema.removeGroup(), and org.exolab.castor.xml.schema.Schema.removeSimpleType().
String org.exolab.castor.xml.schema.Schema.getSchemaLocation | ( | ) |
Returns the schemaLocation hint provided of this schema
Referenced by org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.builder.SourceGenerator.generateSource(), org.exolab.castor.builder.binding.XMLBindingComponent.getSchemaLocation(), org.exolab.castor.xml.schema.reader.ImportUnmarshaller.ImportUnmarshaller(), org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller(), org.exolab.castor.xml.schema.RedefineSchema.RedefineSchema(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller(), and org.exolab.castor.xml.schema.Schema.removeCachedIncludedSchema().
String org.exolab.castor.xml.schema.Schema.getSchemaNamespace | ( | ) |
Returns the namespace of the XML Schema
Note: This is not the same as targetNamespace. This is the namespace of "XML Schema" itself and not the namespace of the schema that is represented by this object model (see getTargetNamespace).
Referenced by org.exolab.castor.xml.schema.TypeReference.resolveTypeReference().
SimpleType org.exolab.castor.xml.schema.Schema.getSimpleType | ( | String | name | ) |
Returns the SimpleType associated with the given name, or null if no such SimpleType exists.
name | the name of the SimpleType. The name may be a QName (contain a namespace prefix). |
References org.exolab.castor.xml.Namespaces.getNamespaceURI().
Referenced by org.exolab.castor.xml.schema.Schema.addSimpleType(), org.exolab.castor.xml.schema.SimpleTypesFactory.createUserSimpleType(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.xml.schema.Schema.getSimpleType(), org.exolab.castor.xml.schema.AttributeDecl.getSimpleType(), org.exolab.castor.xml.schema.Schema.getType(), org.exolab.castor.xml.schema.TypeReference.resolveTypeReference(), and org.exolab.castor.xml.schema.SimpleTypeReference.resolveTypeReference().
SimpleType org.exolab.castor.xml.schema.Schema.getSimpleType | ( | String | name, | |
String | namespace | |||
) |
Returns the SimpleType associated with the given name and namespace, or null if no such SimpleType exists.
name | the name of the simpleType. It is an error if this name contains a prefix, it must be an NCName. | |
namespace | the namespace URI of the simpleType. |
References org.exolab.castor.xml.schema.SimpleTypesFactory.getBuiltInType(), org.exolab.castor.xml.schema.Schema.getImportedSchema(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.getSimpleType(), org.exolab.castor.xml.schema.Schema.getSimpleType(), org.exolab.castor.xml.schema.XMLType.getType(), org.exolab.castor.xml.schema.RedefineSchema.hasSimpleTypeRedefinition(), org.exolab.castor.xml.schema.Schema.setMasterSchema(), and org.exolab.castor.xml.schema.SimpleType.setParent().
Enumeration org.exolab.castor.xml.schema.Schema.getSimpleTypes | ( | ) |
Returns an Enumeration of all SimpleType declarations
References org.exolab.castor.xml.schema.RedefineSchema.enumerateSimpleTypes(), org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.RedefineSchema.getOriginalSchema(), org.exolab.castor.xml.schema.Schema.getSimpleTypes(), org.exolab.castor.xml.schema.XMLType.getType(), org.exolab.castor.xml.schema.RedefineSchema.hasSimpleTypeRedefinition(), org.exolab.castor.xml.schema.Schema.setMasterSchema(), and org.exolab.castor.xml.schema.SimpleType.setParent().
Referenced by org.exolab.castor.xml.schema.Schema.getSimpleTypes().
short org.exolab.castor.xml.schema.Schema.getStructureType | ( | ) | [virtual] |
Returns the type of this Schema Structure
Implements org.exolab.castor.xml.schema.Structure.
String org.exolab.castor.xml.schema.Schema.getTargetNamespace | ( | ) |
Returns the target namespace for this Schema, or null if no namespace has been defined.
Referenced by org.exolab.castor.xml.schema.RedefineSchema.addAttributeGroup(), org.exolab.castor.builder.TypeConversion.convertType(), org.exolab.castor.builder.MemberFactory.createFieldInfoForAny(), org.exolab.castor.builder.SourceFactory.createSourceCode(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.endElement(), org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace(), org.exolab.castor.xml.schema.reader.ImportUnmarshaller.ImportUnmarshaller(), org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller(), org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller(), org.exolab.castor.xml.schema.Schema.removeImportedSchema(), org.exolab.castor.xml.schema.ElementDecl.setReference(), and org.exolab.castor.xml.schema.reader.SimpleTypeUnmarshaller.SimpleTypeUnmarshaller().
XMLType org.exolab.castor.xml.schema.Schema.getType | ( | String | typeName | ) |
Returns the first simple or complex type which name equals TypeName
References org.exolab.castor.xml.schema.Schema.DEFAULT_SCHEMA_NS, org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.Namespaces.getNamespaceURI(), and org.exolab.castor.xml.schema.Schema.getSimpleType().
Referenced by org.exolab.castor.xml.schema.reader.ComplexContentRestrictionUnmarshaller.ComplexContentRestrictionUnmarshaller(), org.exolab.castor.xml.schema.reader.ComplexTypeUnmarshaller.ComplexTypeUnmarshaller(), org.exolab.castor.xml.schema.reader.ExtensionUnmarshaller.ExtensionUnmarshaller(), org.exolab.castor.xml.schema.ComplexType.getBaseType(), org.exolab.castor.xml.schema.SimpleContent.getSimpleType(), org.exolab.castor.xml.schema.ElementDecl.getType(), org.exolab.castor.xml.schema.reader.SimpleContentRestrictionUnmarshaller.SimpleContentRestrictionUnmarshaller(), org.exolab.castor.xml.schema.reader.SimpleTypeListUnmarshaller.SimpleTypeListUnmarshaller(), and org.exolab.castor.xml.schema.reader.SimpleTypeRestrictionUnmarshaller.SimpleTypeRestrictionUnmarshaller().
static SimpleTypesFactory org.exolab.castor.xml.schema.Schema.getTypeFactory | ( | ) | [static, package] |
Gets the type factory, package private
String org.exolab.castor.xml.schema.Schema.getVersion | ( | ) |
boolean org.exolab.castor.xml.schema.Schema.includeProcessed | ( | String | includeFile | ) |
Returns True if the given XML Schema has already been included via <xs:include>
Referenced by org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller().
boolean org.exolab.castor.xml.schema.Schema.isKnownNamespace | ( | String | namespaceURL | ) |
Returns True if the namespace is known to this schema
namespace | the namespace URL |
References org.exolab.castor.xml.Namespaces.getNamespacePrefix().
boolean org.exolab.castor.xml.schema.Schema.removeAttribute | ( | AttributeDecl | attribute | ) |
Removes the given top level Attribute from this Schema
attribute | the AttributeDecl to remove |
References org.exolab.castor.xml.schema.AttributeDecl.getName(), and org.exolab.castor.xml.schema.Schema.removeAttribute().
Referenced by org.exolab.castor.xml.schema.Schema.removeAttribute().
boolean org.exolab.castor.xml.schema.Schema.removeAttributeGroup | ( | AttributeGroupDecl | group | ) |
Removes the given AttributeGroup definition from this Schema
group | the AttributeGroup definition to remove |
References org.exolab.castor.xml.schema.AttributeGroupDecl.getName(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.removeAttributeGroup(), and org.exolab.castor.xml.schema.Schema.removeAttributeGroup().
Referenced by org.exolab.castor.xml.schema.Schema.removeAttributeGroup().
synchronized boolean org.exolab.castor.xml.schema.Schema.removeCachedIncludedSchema | ( | Schema | schema | ) |
Removes the given cached included schema from this Schema definition's list of cached included schema.
schema | the Schema to remove from this Schema's redefinition list |
References org.exolab.castor.xml.schema.Schema.getSchemaLocation().
boolean org.exolab.castor.xml.schema.Schema.removeComplexType | ( | ComplexType | complexType | ) |
Removes the given top level ComplexType from this Schema
complexType | the ComplexType to remove |
References org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.ComplexType.isTopLevel(), org.exolab.castor.xml.schema.RedefineSchema.removeComplexType(), org.exolab.castor.xml.schema.Schema.removeComplexType(), and org.exolab.castor.xml.schema.ComplexType.setParent().
Referenced by org.exolab.castor.xml.schema.Schema.removeComplexType(), and org.exolab.castor.xml.schema.XMLType.setName().
boolean org.exolab.castor.xml.schema.Schema.removeElement | ( | ElementDecl | element | ) |
Removes the given top level Element from this Schema
element | the ElementDecl to remove |
References org.exolab.castor.xml.schema.ElementDecl.getName(), and org.exolab.castor.xml.schema.Schema.removeElement().
Referenced by org.exolab.castor.xml.schema.Schema.removeElement().
boolean org.exolab.castor.xml.schema.Schema.removeGroup | ( | ModelGroup | group | ) |
Removes the given top level ModelGroup definition from this Schema
group | the ModelGroup definition to remove |
References org.exolab.castor.xml.schema.ModelGroup.getName(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.removeGroup(), and org.exolab.castor.xml.schema.Schema.removeGroup().
Referenced by org.exolab.castor.xml.schema.Schema.removeGroup().
synchronized boolean org.exolab.castor.xml.schema.Schema.removeImportedSchema | ( | Schema | schema | ) |
Removes the given Schema definition from this Schema definition's list of imported schenma
schema | the Schema to remove from this Schema's import list |
References org.exolab.castor.xml.schema.Schema.getTargetNamespace().
boolean org.exolab.castor.xml.schema.Schema.removeNamespace | ( | String | prefix | ) |
Removes the namespace from the set of namespace declarations for this Schema definition.
prefix | the namespace prefix of the namespace to remove. |
References org.exolab.castor.xml.Namespaces.removeNamespace().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.SchemaUnmarshaller().
synchronized boolean org.exolab.castor.xml.schema.Schema.removeRedefineSchema | ( | RedefineSchema | schema | ) |
Removes the given redefined structure from this Schema definition's list of redefinitions.
schema | the Schema to remove from this Schema's redefinition list |
References org.exolab.castor.xml.schema.RedefineSchema.getSchemaLocation().
Referenced by org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.endElement().
boolean org.exolab.castor.xml.schema.Schema.removeSimpleType | ( | SimpleType | simpleType | ) |
Removes the given top level SimpleType from this Schema
SimpleType | the SimpleType to remove |
References org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.Schema.getRedefineSchema(), org.exolab.castor.xml.schema.RedefineSchema.removeSimpleType(), and org.exolab.castor.xml.schema.Schema.removeSimpleType().
Referenced by org.exolab.castor.xml.schema.Schema.removeSimpleType(), and org.exolab.castor.xml.schema.XMLType.setName().
void org.exolab.castor.xml.schema.Schema.setAttributeFormDefault | ( | Form | attributeFormDefault | ) |
void org.exolab.castor.xml.schema.Schema.setBlockDefault | ( | BlockList | block | ) |
void org.exolab.castor.xml.schema.Schema.setBlockDefault | ( | String | block | ) |
void org.exolab.castor.xml.schema.Schema.setElementFormDefault | ( | Form | elementFormDefault | ) |
void org.exolab.castor.xml.schema.Schema.setFinalDefault | ( | FinalList | finalList | ) |
void org.exolab.castor.xml.schema.Schema.setFinalDefault | ( | String | finalValues | ) |
void org.exolab.castor.xml.schema.Schema.setId | ( | String | id | ) |
Sets the Id for this Schema
id | the Id for this Schema |
Referenced by org.exolab.castor.xml.dtd.Converter.convertDTDObjectToSchemaObject().
void org.exolab.castor.xml.schema.Schema.setMasterSchema | ( | Schema | masterSchema | ) | [protected] |
Sets the master schema in which this instance of schema is used at runtime. This method is meant to be used at runtime. A master schema is a schema in which this instance of Schema is included, redefined or imported.
the | master schema in which this instance of schema is used at runtime. This method is meant to be used at runtime. |
Referenced by org.exolab.castor.xml.schema.Schema.getAttribute(), org.exolab.castor.xml.schema.Schema.getAttributeGroup(), org.exolab.castor.xml.schema.Schema.getAttributeGroups(), org.exolab.castor.xml.schema.Schema.getAttributes(), org.exolab.castor.xml.schema.Schema.getComplexType(), org.exolab.castor.xml.schema.Schema.getComplexTypes(), org.exolab.castor.xml.schema.Schema.getElementDecl(), org.exolab.castor.xml.schema.Schema.getElementDecls(), org.exolab.castor.xml.schema.Schema.getModelGroup(), org.exolab.castor.xml.schema.Schema.getModelGroups(), org.exolab.castor.xml.schema.Schema.getSimpleType(), and org.exolab.castor.xml.schema.Schema.getSimpleTypes().
void org.exolab.castor.xml.schema.Schema.setSchemaLocation | ( | String | schemaLocation | ) |
Set the schemaLocation for this schema. This is useful when this schema has been imported by another schema
schemaLocation | the location hint for this Schema |
Referenced by org.exolab.castor.xml.schema.reader.ImportUnmarshaller.ImportUnmarshaller(), and org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller().
void org.exolab.castor.xml.schema.Schema.setTargetNamespace | ( | String | targetNamespace | ) |
Sets the target namespace for this Schema
targetNamespace | the target namespace for this Schema |
Referenced by org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.IncludeUnmarshaller(), and org.exolab.castor.xml.schema.reader.RedefineUnmarshaller.RedefineUnmarshaller().
void org.exolab.castor.xml.schema.Schema.setVersion | ( | String | version | ) |
void org.exolab.castor.xml.schema.Schema.validate | ( | ) | throws ValidationException [virtual] |
Checks the validity of this Schema definition.
ValidationException | when this Schema definition is invalid. |
Implements org.exolab.castor.xml.schema.Structure.
References org.exolab.castor.xml.schema.SimpleType.validate(), and org.exolab.castor.xml.schema.ComplexType.validate().
Referenced by org.exolab.castor.builder.SourceGenerator.generateSource(), and org.exolab.castor.xml.schema.reader.SchemaReader.read().
final String org.exolab.castor.xml.schema.Schema.DEFAULT_SCHEMA_NS = "http://www.w3.org/2001/XMLSchema" [static] |
The Namespace supported by the W3C XML Schema Recommendation.
Referenced by org.exolab.castor.xml.schema.Schema.getType(), and org.exolab.castor.xml.schema.Schema.Schema().
final String org.exolab.castor.xml.schema.Schema.XSI_NAMESPACE = "http://www.w3.org/2001/XMLSchema-instance" [static] |
The Namespace supported by the W3C XML Schema Recommendation for the built-in types: xsi:type, xsi:nil, and xsi:schemaLocation.