org.apache.axiom.om.impl.dom.factory
Class OMDOMFactory

java.lang.Object
  extended by org.apache.axiom.om.impl.dom.factory.OMDOMFactory
All Implemented Interfaces:
org.apache.axiom.om.OMFactory
Direct Known Subclasses:
DOMSOAPFactory

public class OMDOMFactory
extends java.lang.Object
implements org.apache.axiom.om.OMFactory


Field Summary
protected  DocumentImpl document
           
 
Constructor Summary
OMDOMFactory()
           
OMDOMFactory(DocumentImpl doc)
           
 
Method Summary
 org.apache.axiom.om.OMAttribute createOMAttribute(java.lang.String localName, org.apache.axiom.om.OMNamespace ns, java.lang.String value)
           
 org.apache.axiom.om.OMComment createOMComment(org.apache.axiom.om.OMContainer parent, java.lang.String content)
           
 org.apache.axiom.om.OMDocType createOMDocType(org.apache.axiom.om.OMContainer parent, java.lang.String content)
           
 org.apache.axiom.om.OMDocument createOMDocument()
           
 org.apache.axiom.om.OMDocument createOMDocument(org.apache.axiom.om.OMXMLParserWrapper builder)
           
 org.apache.axiom.om.OMSourcedElement createOMElement(org.apache.axiom.om.OMDataSource source, java.lang.String localName, org.apache.axiom.om.OMNamespace ns)
           
 org.apache.axiom.om.OMElement createOMElement(org.apache.axiom.om.OMDataSource source, java.lang.String localName, org.apache.axiom.om.OMNamespace ns, org.apache.axiom.om.OMContainer parent)
           
 org.apache.axiom.om.OMElement createOMElement(javax.xml.namespace.QName qname)
          Create an OMElement with the given QName

If the QName contains a prefix, we will ensure that an OMNamespace is created mapping the given namespace to the given prefix.

 org.apache.axiom.om.OMElement createOMElement(javax.xml.namespace.QName qname, org.apache.axiom.om.OMContainer parent)
          Creates a new OMDOM Element node and adds it to the given parent.
 org.apache.axiom.om.OMElement createOMElement(java.lang.String localName, org.apache.axiom.om.OMNamespace ns)
           
 org.apache.axiom.om.OMElement createOMElement(java.lang.String localName, org.apache.axiom.om.OMNamespace ns, org.apache.axiom.om.OMContainer parent)
           
 org.apache.axiom.om.OMElement createOMElement(java.lang.String localName, org.apache.axiom.om.OMNamespace ns, org.apache.axiom.om.OMContainer parent, org.apache.axiom.om.OMXMLParserWrapper builder)
          Creates an OMElement with the builder.
 org.apache.axiom.om.OMElement createOMElement(java.lang.String localName, java.lang.String namespaceURI, java.lang.String namespacePrefix)
          Creates an OMElement.
 org.apache.axiom.om.OMNamespace createOMNamespace(java.lang.String uri, java.lang.String prefix)
          Creates a new OMNamespace.
 org.apache.axiom.om.OMProcessingInstruction createOMProcessingInstruction(org.apache.axiom.om.OMContainer parent, java.lang.String piTarget, java.lang.String piData)
           
 org.apache.axiom.om.OMText createOMText(java.lang.Object dataHandler, boolean optimize)
          Creates a new OMDOM Text node with the given datahandler and the given MTOM optimization configuration and returns it.
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, char[] charArary, int type)
           
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, org.apache.axiom.om.OMText source)
          Create OMText node that is a copy of the source text node
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, javax.xml.namespace.QName text)
           
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, javax.xml.namespace.QName text, int type)
           
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, java.lang.String text)
          Creates a new OMDOM Text node with the given value and appends it to the given parent element.
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, java.lang.String text, int type)
           
 org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent, java.lang.String s, java.lang.String mimeType, boolean optimize)
          Creates an OMDOM Text node, adds it to the give parent element and returns it.
 org.apache.axiom.om.OMText createOMText(java.lang.String s)
          Creates a OMDOM Text node carrying the given value.
 org.apache.axiom.om.OMText createOMText(java.lang.String text, int type)
          Creates a Character node of the given type.
 org.apache.axiom.om.OMText createOMText(java.lang.String contentID, org.apache.axiom.om.OMContainer parent, org.apache.axiom.om.OMXMLParserWrapper builder)
           
 org.apache.axiom.om.OMText createOMText(java.lang.String text, java.lang.String mimeType, boolean optimize)
          Creates a new OMDOM Text node with the value of the given text value along with the MTOM optimization parameters and returns it.
 DocumentImpl getDocument()
           
 void setDocument(DocumentImpl document)
          Configure this factory to use the given document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

document

protected DocumentImpl document
Constructor Detail

OMDOMFactory

public OMDOMFactory()

OMDOMFactory

public OMDOMFactory(DocumentImpl doc)
Method Detail

createOMDocument

public org.apache.axiom.om.OMDocument createOMDocument()
Specified by:
createOMDocument in interface org.apache.axiom.om.OMFactory

setDocument

public void setDocument(DocumentImpl document)
Configure this factory to use the given document. Use with care.

Parameters:
document -

createOMElement

public org.apache.axiom.om.OMElement createOMElement(java.lang.String localName,
                                                     org.apache.axiom.om.OMNamespace ns)
Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory

createOMElement

public org.apache.axiom.om.OMElement createOMElement(java.lang.String localName,
                                                     org.apache.axiom.om.OMNamespace ns,
                                                     org.apache.axiom.om.OMContainer parent)
                                              throws OMDOMException
Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory
Throws:
OMDOMException

createOMElement

public org.apache.axiom.om.OMElement createOMElement(java.lang.String localName,
                                                     org.apache.axiom.om.OMNamespace ns,
                                                     org.apache.axiom.om.OMContainer parent,
                                                     org.apache.axiom.om.OMXMLParserWrapper builder)
Creates an OMElement with the builder.

Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory

createOMElement

public org.apache.axiom.om.OMElement createOMElement(org.apache.axiom.om.OMDataSource source,
                                                     java.lang.String localName,
                                                     org.apache.axiom.om.OMNamespace ns,
                                                     org.apache.axiom.om.OMContainer parent)

createOMElement

public org.apache.axiom.om.OMSourcedElement createOMElement(org.apache.axiom.om.OMDataSource source,
                                                            java.lang.String localName,
                                                            org.apache.axiom.om.OMNamespace ns)
Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory

createOMElement

public org.apache.axiom.om.OMElement createOMElement(java.lang.String localName,
                                                     java.lang.String namespaceURI,
                                                     java.lang.String namespacePrefix)
Creates an OMElement.

Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMElement(String, String, String)

createOMElement

public org.apache.axiom.om.OMElement createOMElement(javax.xml.namespace.QName qname,
                                                     org.apache.axiom.om.OMContainer parent)
                                              throws org.apache.axiom.om.OMException
Creates a new OMDOM Element node and adds it to the given parent.

Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory
Throws:
org.apache.axiom.om.OMException
See Also:
createOMElement(String, OMNamespace, OMContainer), OMFactory.createOMElement( javax.xml.namespace.QName, org.apache.axiom.om.OMContainer)

createOMElement

public org.apache.axiom.om.OMElement createOMElement(javax.xml.namespace.QName qname)
                                              throws org.apache.axiom.om.OMException
Create an OMElement with the given QName

If the QName contains a prefix, we will ensure that an OMNamespace is created mapping the given namespace to the given prefix. If no prefix is passed, we'll create a generated one.

Specified by:
createOMElement in interface org.apache.axiom.om.OMFactory
Parameters:
qname -
Returns:
the new OMElement.
Throws:
org.apache.axiom.om.OMException

createOMNamespace

public org.apache.axiom.om.OMNamespace createOMNamespace(java.lang.String uri,
                                                         java.lang.String prefix)
Creates a new OMNamespace.

Specified by:
createOMNamespace in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMNamespace(String, String)

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               java.lang.String text)
Creates a new OMDOM Text node with the given value and appends it to the given parent element.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
org.apache.axiom.om.OMFactory#createOMText( org.apache.axiom.om.OMElement,String)

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               javax.xml.namespace.QName text)
Specified by:
createOMText in interface org.apache.axiom.om.OMFactory

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               javax.xml.namespace.QName text,
                                               int type)
Specified by:
createOMText in interface org.apache.axiom.om.OMFactory

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               java.lang.String text,
                                               int type)
Specified by:
createOMText in interface org.apache.axiom.om.OMFactory

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               org.apache.axiom.om.OMText source)
Create OMText node that is a copy of the source text node

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
Parameters:
parent -
source -
Returns:

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               char[] charArary,
                                               int type)
Specified by:
createOMText in interface org.apache.axiom.om.OMFactory

createOMText

public org.apache.axiom.om.OMText createOMText(java.lang.String s)
Creates a OMDOM Text node carrying the given value.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMText(String)

createOMText

public org.apache.axiom.om.OMText createOMText(java.lang.String text,
                                               int type)
Creates a Character node of the given type.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMText(String, int)

createOMText

public org.apache.axiom.om.OMText createOMText(java.lang.String text,
                                               java.lang.String mimeType,
                                               boolean optimize)
Creates a new OMDOM Text node with the value of the given text value along with the MTOM optimization parameters and returns it.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMText(String, String, boolean)

createOMText

public org.apache.axiom.om.OMText createOMText(java.lang.Object dataHandler,
                                               boolean optimize)
Creates a new OMDOM Text node with the given datahandler and the given MTOM optimization configuration and returns it.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMText(Object, boolean)

createOMText

public org.apache.axiom.om.OMText createOMText(org.apache.axiom.om.OMContainer parent,
                                               java.lang.String s,
                                               java.lang.String mimeType,
                                               boolean optimize)
Creates an OMDOM Text node, adds it to the give parent element and returns it.

Specified by:
createOMText in interface org.apache.axiom.om.OMFactory
See Also:
OMFactory.createOMText(OMContainer, String, String, boolean)

createOMText

public org.apache.axiom.om.OMText createOMText(java.lang.String contentID,
                                               org.apache.axiom.om.OMContainer parent,
                                               org.apache.axiom.om.OMXMLParserWrapper builder)
Specified by:
createOMText in interface org.apache.axiom.om.OMFactory

createOMAttribute

public org.apache.axiom.om.OMAttribute createOMAttribute(java.lang.String localName,
                                                         org.apache.axiom.om.OMNamespace ns,
                                                         java.lang.String value)
Specified by:
createOMAttribute in interface org.apache.axiom.om.OMFactory

createOMDocType

public org.apache.axiom.om.OMDocType createOMDocType(org.apache.axiom.om.OMContainer parent,
                                                     java.lang.String content)
Specified by:
createOMDocType in interface org.apache.axiom.om.OMFactory

createOMProcessingInstruction

public org.apache.axiom.om.OMProcessingInstruction createOMProcessingInstruction(org.apache.axiom.om.OMContainer parent,
                                                                                 java.lang.String piTarget,
                                                                                 java.lang.String piData)
Specified by:
createOMProcessingInstruction in interface org.apache.axiom.om.OMFactory

createOMComment

public org.apache.axiom.om.OMComment createOMComment(org.apache.axiom.om.OMContainer parent,
                                                     java.lang.String content)
Specified by:
createOMComment in interface org.apache.axiom.om.OMFactory

getDocument

public DocumentImpl getDocument()

createOMDocument

public org.apache.axiom.om.OMDocument createOMDocument(org.apache.axiom.om.OMXMLParserWrapper builder)
Specified by:
createOMDocument in interface org.apache.axiom.om.OMFactory