Top Description Fields Constructors Methods
org.dom4j.datatype

public Class DatatypeDocumentFactory

extends DocumentFactory
Class Inheritance
Imports
org.dom4j.Attribute, .Document, .DocumentFactory, .Element, .Namespace, .QName, org.dom4j.io.SAXReader, org.xml.sax.EntityResolver, .InputSource

DatatypeDocumentFactory is a factory of XML objects which support the XML Schema Data Types specification.

Author
James Strachan
Version
$Revision: 1.9 $

Field Summary

Modifier and TypeField and Description
private boolean
autoLoadSchema

If schemas are automatically loaded when parsing instance documents

private static final boolean
private SchemaParser
schemaBuilder

The builder of XML Schemas

protected static transient DatatypeDocumentFactory
singleton

Hides org.dom4j.DocumentFactory.singleton.

The Singleton instance
private SAXReader
xmlSchemaReader

reader of XML Schemas

private static final Namespace
private static final QName
private static final QName
Inherited from org.dom4j.DocumentFactory:
cache

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Attribute
public DatatypeElementFactory

Returns:

DOCUMENT ME!
getElementFactory
(QName
DOCUMENT ME!
elementQName
)

Registers the given DatatypeElementFactory for the given <element> schema element

public static DocumentFactory

Returns:

the default singleon instance
getInstance
()

Hides org.dom4j.DocumentFactory.getInstance.

Access to the singleton instance of this factory.

public void
loadSchema(Document
is an XML Schema Document instance.
schemaDocument
)

Loads the given XML Schema document into this factory so schema-aware Document, Elements and Attributes will be created by this factory.

public void
loadSchema(Document schemaDocument, Namespace targetNamespace)

protected void
loadSchema(Document document, String schemaInstanceURI)

protected void
loadSchema(Document document, String schemaInstanceURI, Namespace namespace)

Inherited from org.dom4j.DocumentFactory:
createAttributecreateCDATAcreateCommentcreateDocTypecreateDocumentcreateDocumentcreateDocumentcreateElementcreateElementcreateElementcreateEntitycreateNamespacecreatePatterncreateProcessingInstructioncreateProcessingInstructioncreateQNamecreateQNamecreateQNamecreateQNamecreateQNameCachecreateSingletoncreateTextcreateXPathcreateXPathcreateXPathFiltercreateXPathFiltergetQNamesgetXPathNamespaceURIsinitinternsetXPathNamespaceURIs

Field Detail

autoLoadSchemaback to summary
private boolean autoLoadSchema

If schemas are automatically loaded when parsing instance documents

DO_INTERN_QNAMEback to summary
private static final boolean DO_INTERN_QNAME
schemaBuilderback to summary
private SchemaParser schemaBuilder

The builder of XML Schemas

singletonback to summary
protected static transient DatatypeDocumentFactory singleton

Hides org.dom4j.DocumentFactory.singleton.

The Singleton instance

xmlSchemaReaderback to summary
private SAXReader xmlSchemaReader

reader of XML Schemas

XSI_NAMESPACEback to summary
private static final Namespace XSI_NAMESPACE
XSI_NO_SCHEMA_LOCATIONback to summary
private static final QName XSI_NO_SCHEMA_LOCATION
XSI_SCHEMA_LOCATIONback to summary
private static final QName XSI_SCHEMA_LOCATION

Constructor Detail

DatatypeDocumentFactoryback to summary
public DatatypeDocumentFactory()

Method Detail

createAttributeback to summary
public Attribute createAttribute(Element owner, QName qname, String value)

Overrides org.dom4j.DocumentFactory.createAttribute.

getElementFactoryback to summary
public DatatypeElementFactory getElementFactory(QName elementQName)

Registers the given DatatypeElementFactory for the given <element> schema element

Parameters
elementQName:QName

DOCUMENT ME!

Returns:DatatypeElementFactory

DOCUMENT ME!

getInstanceback to summary
public static DocumentFactory getInstance()

Hides org.dom4j.DocumentFactory.getInstance.

Access to the singleton instance of this factory.

Returns:DocumentFactory

the default singleon instance

loadSchemaback to summary
public void loadSchema(Document schemaDocument)

Loads the given XML Schema document into this factory so schema-aware Document, Elements and Attributes will be created by this factory.

Parameters
schemaDocument:Document

is an XML Schema Document instance.

loadSchemaback to summary
public void loadSchema(Document schemaDocument, Namespace targetNamespace)
loadSchemaback to summary
protected void loadSchema(Document document, String schemaInstanceURI)
loadSchemaback to summary
protected void loadSchema(Document document, String schemaInstanceURI, Namespace namespace)