DocumentFactory is a collection of factory methods to allow
easy custom building of DOM4J trees. The default tree that is built uses a
doubly linked tree.
The tree built allows full XPath expressions from anywhere on the tree.
| Modifier and Type | Field and Description |
|---|---|
| protected transient QNameCache | |
| private static SingletonStrategy | |
| private Map | xpathNamespaceURIs
Default namespace prefix → URI mappings for XPath expressions to use |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Attribute | |
| public Attribute | |
| public CDATA | |
| public Comment | |
| public DocumentType | |
| public Document | |
| public Document | |
| public Document | |
| public Element | |
| public Element | |
| public Element | |
| public Entity | |
| public Namespace | |
| public Pattern | Returns: a newPattern instanceis the XPath pattern expression to create xpathPattern)
|
| public ProcessingInstruction | |
| public ProcessingInstruction | |
| public QName | |
| public QName | |
| public QName | |
| public QName | |
| protected QNameCache | |
| private static SingletonStrategy | |
| protected static DocumentFactory | Returns: a new singleton instance.is the name of the DocumentFactory class to use className)
|
| public Text | |
| public XPath | Returns: a newXPath instanceis the XPath expression to create xpathExpression)
|
| public XPath | Returns: a newXPath instanceis the XPath expression to create xpathExpression, VariableContext is the variable context to use when evaluating the XPath variableContext)
|
| public NodeFilter | Returns: a newNodeFilter instanceis the XPath filter expression to create xpathFilterExpression, VariableContext is the variable context to use when evaluating the XPath variableContext)
|
| public NodeFilter | Returns: a newNodeFilter instanceis the XPath filter expression to create xpathFilterExpression)
|
| public static synchronized DocumentFactory | Returns: the default singleon instanceAccess to singleton implementation of DocumentFactory which is used if no DocumentFactory is specified when building using the standard builders. |
| public List | Returns: DOCUMENT ME!Returns a list of all the QName instances currently used by this document factory |
| public Map | Returns: the Map of namespace URIs that will be used by by XPath expressions to resolve namespace prefixes into namespace URIs. The map is keyed by namespace prefix and the value is the namespace URI. This value could well be null to indicate no namespace URIs are being mapped.DOCUMENT ME! |
| protected void | |
| protected QName | |
| private void | |
| public void | setXPathNamespaceURIs(Map<String, String>
DOCUMENT ME! namespaceURIs)Sets the namespace URIs to be used by XPath expressions created by this factory or by nodes associated with this factory. |
| cache | back to summary |
|---|---|
| protected transient QNameCache cache | |
| singleton | back to summary |
|---|---|
| private static SingletonStrategy<DocumentFactory> singleton | |
| xpathNamespaceURIs | back to summary |
|---|---|
| private Map<String, String> xpathNamespaceURIs Default namespace prefix → URI mappings for XPath expressions to use | |
| DocumentFactory | back to summary |
|---|---|
| public DocumentFactory() | |
| createAttribute | back to summary |
|---|---|
| public Attribute createAttribute(Element owner, QName qname, String value) | |
| createAttribute | back to summary |
|---|---|
| public Attribute createAttribute(Element owner, String name, String value) | |
| createCDATA | back to summary |
|---|---|
| public CDATA createCDATA(String text) | |
| createComment | back to summary |
|---|---|
| public Comment createComment(String text) | |
| createDocType | back to summary |
|---|---|
| public DocumentType createDocType(String name, String publicId, String systemId) | |
| createDocument | back to summary |
|---|---|
| public Document createDocument() | |
| createDocument | back to summary |
|---|---|
| public Document createDocument(String encoding) DOCUMENT ME! | |
| createDocument | back to summary |
|---|---|
| public Document createDocument(Element rootElement) | |
| createElement | back to summary |
|---|---|
| public Element createElement(QName qname) | |
| createElement | back to summary |
|---|---|
| public Element createElement(String name) | |
| createElement | back to summary |
|---|---|
| public Element createElement(String qualifiedName, String namespaceURI) | |
| createEntity | back to summary |
|---|---|
| public Entity createEntity(String name, String text) | |
| createNamespace | back to summary |
|---|---|
| public Namespace createNamespace(String prefix, String uri) | |
| createPattern | back to summary |
|---|---|
| public Pattern createPattern(String xpathPattern)
| |
| createProcessingInstruction | back to summary |
|---|---|
| public ProcessingInstruction createProcessingInstruction(String target, String data) | |
| createProcessingInstruction | back to summary |
|---|---|
| public ProcessingInstruction createProcessingInstruction(String target, Map<String, String> data) | |
| createQName | back to summary |
|---|---|
| public QName createQName(String localName, Namespace namespace) | |
| createQName | back to summary |
|---|---|
| public QName createQName(String localName) | |
| createQName | back to summary |
|---|---|
| public QName createQName(String name, String prefix, String uri) | |
| createQName | back to summary |
|---|---|
| public QName createQName(String qualifiedName, String uri) | |
| createQNameCache | back to summary |
|---|---|
| protected QNameCache createQNameCache() Factory method to create the QNameCache. This method should be overloaded if you wish to use your own derivation of QName.
| |
| createSingleton | back to summary |
|---|---|
| private static SingletonStrategy | |
| createSingleton | back to summary |
|---|---|
| protected static DocumentFactory createSingleton(String className)
| |
| createText | back to summary |
|---|---|
| public Text createText(String text) | |
| createXPath | back to summary |
|---|---|
| public XPath createXPath(String xpathExpression) throws InvalidXPathException
| |
| createXPath | back to summary |
|---|---|
| public XPath createXPath(String xpathExpression, VariableContext variableContext)
| |
| createXPathFilter | back to summary |
|---|---|
| public NodeFilter createXPathFilter(String xpathFilterExpression, VariableContext variableContext)
| |
| createXPathFilter | back to summary |
|---|---|
| public NodeFilter createXPathFilter(String xpathFilterExpression)
| |
| getInstance | back to summary |
|---|---|
| public static synchronized DocumentFactory getInstance() Access to singleton implementation of DocumentFactory which is used if no DocumentFactory is specified when building using the standard builders.
| |
| getQNames | back to summary |
|---|---|
| public List Returns a list of all the QName instances currently used by this document factory | |
| getXPathNamespaceURIs | back to summary |
|---|---|
| public Map DOCUMENT ME! | |
| init | back to summary |
|---|---|
| protected void init() | |
| intern | back to summary |
|---|---|
| protected QName intern(QName qname) DOCUMENT ME! | |
| readObject | back to summary |
|---|---|
| private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException | |
| setXPathNamespaceURIs | back to summary |
|---|---|
| public void setXPathNamespaceURIs(Map<String, String> namespaceURIs) Sets the namespace URIs to be used by XPath expressions created by this factory or by nodes associated with this factory. The keys are namespace prefixes and the values are namespace URIs. | |