|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.axiom.om.impl.dom.NodeImpl
org.apache.axis2.saaj.NodeImplEx
org.apache.axis2.saaj.SOAPElementImpl
Field Summary | |
protected org.apache.axiom.om.impl.dom.ElementImpl |
element
Using a delegate because we can't extend from org.apache.axiom.om.impl.dom.ElementImpl since this class must extend SNodeImpl |
Fields inherited from class org.apache.axis2.saaj.NodeImplEx |
parentElement |
Fields inherited from class org.apache.axiom.om.impl.dom.NodeImpl |
builder, done, factory, FIRSTCHILD, flags, nodeType, NORMALIZED, OWNED, ownerNode, READONLY, SPECIFIED |
Fields inherited from interface org.w3c.dom.Node |
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE |
Fields inherited from interface org.apache.axiom.om.OMNode |
CDATA_SECTION_NODE, COMMENT_NODE, DTD_NODE, ELEMENT_NODE, ENTITY_REFERENCE_NODE, PI_NODE, SPACE_NODE, TEXT_NODE |
Constructor Summary | |
SOAPElementImpl(org.apache.axiom.om.impl.dom.ElementImpl element)
|
Method Summary | |
SOAPElement |
addAttribute(Name name,
String value)
Adds an attribute with the specified name and value to this SOAPElement object. |
SOAPElement |
addChildElement(Name name)
|
SOAPElement |
addChildElement(SOAPElement soapElement)
|
SOAPElement |
addChildElement(String localName)
|
SOAPElement |
addChildElement(String localName,
String prefix)
|
SOAPElement |
addChildElement(String localName,
String prefix,
String uri)
|
SOAPElement |
addNamespaceDeclaration(String prefix,
String uri)
|
SOAPElement |
addTextNode(String text)
Creates a new Text object initialized with the given
String and adds it to this SOAPElement object. |
org.apache.axiom.om.OMNode |
detach()
|
void |
detachNode()
Removes this Node object from the tree. |
void |
discard()
|
Iterator |
getAllAttributes()
Returns an iterator over all of the attribute names in this SOAPElement object. |
String |
getAttribute(String name)
|
Attr |
getAttributeNode(String name)
|
Attr |
getAttributeNodeNS(String namespaceURI,
String localName)
|
String |
getAttributeNS(String namespaceURI,
String localName)
|
String |
getAttributeValue(Name name)
|
Iterator |
getChildElements()
Returns an iterator over all the immediate content of this element. |
Iterator |
getChildElements(Name name)
|
NodeList |
getChildNodes()
|
org.apache.axiom.om.impl.dom.ElementImpl |
getElement()
|
Name |
getElementName()
|
NodeList |
getElementsByTagName(String name)
|
NodeList |
getElementsByTagNameNS(String namespaceURI,
String localName)
|
String |
getEncodingStyle()
|
Node |
getFirstChild()
|
Node |
getLastChild()
Method getLastChild |
String |
getLocalName()
|
Iterator |
getNamespacePrefixes()
|
String |
getNamespaceURI()
|
String |
getNamespaceURI(String prefix)
|
Node |
getNextSibling()
dom Node method |
String |
getNodeName()
|
short |
getNodeType()
|
Document |
getOwnerDocument()
Find the Document that this Node belongs to (the document in whose context the Node was created). |
SOAPElement |
getParentElement()
Returns the parent element of this Node object. |
Node |
getParentNode()
|
String |
getPrefix()
|
Node |
getPreviousSibling()
|
String |
getTagName()
|
String |
getValue()
Returns the the value of the immediate child of this Node
object if a child exists and its value is text. |
Iterator |
getVisibleNamespacePrefixes()
|
boolean |
hasAttribute(String name)
|
boolean |
hasAttributeNS(String namespaceURI,
String localName)
|
boolean |
hasChildNodes()
|
void |
internalSerialize(XMLStreamWriter writer)
|
void |
internalSerializeAndConsume(XMLStreamWriter writer)
|
boolean |
removeAttribute(Name name)
|
void |
removeAttribute(String name)
|
Attr |
removeAttributeNode(Attr attr)
|
void |
removeAttributeNS(String namespaceURI,
String localName)
|
void |
removeContents()
|
boolean |
removeNamespaceDeclaration(String prefix)
|
void |
setAttribute(String name,
String value)
|
Attr |
setAttributeNode(Attr attr)
|
Attr |
setAttributeNodeNS(Attr attr)
|
void |
setAttributeNS(String namespaceURI,
String qualifiedName,
String value)
|
void |
setEncodingStyle(String encodingStyle)
|
void |
setParent(org.apache.axiom.om.OMContainer parentElement)
|
void |
setParentElement(SOAPElement parent)
Sets the parent of this Node object to the given
SOAPElement object. |
void |
setValue(String value)
If this is a Text node then this method will set its value, otherwise it sets the value of the immediate (Text) child of this node. |
Methods inherited from class org.apache.axis2.saaj.NodeImplEx |
getParent, getSchemaTypeInfo, getType, recycleNode, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setType |
Methods inherited from class org.apache.axiom.om.impl.dom.NodeImpl |
appendChild, build, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getFeature, getLength, getNextOMSibling, getNodeValue, getOMFactory, getPreviousOMSibling, getTextContent, getUserData, hasAttributes, insertBefore, insertSiblingAfter, insertSiblingBefore, internalSerializeWithCache, isComplete, isDefaultNamespace, isEqualNode, isSameNode, isSupported, item, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, serialize, serialize, serialize, serialize, serialize, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume, setComplete, setNextOMSibling, setNodeValue, setOwnerDocument, setPrefix, setPreviousOMSibling, setTextContent, setUserData |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.xml.soap.Node |
recycleNode |
Methods inherited from interface org.w3c.dom.Node |
appendChild, cloneNode, getAttributes, getNodeValue, hasAttributes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue, setPrefix |
Field Detail |
protected org.apache.axiom.om.impl.dom.ElementImpl element
Constructor Detail |
public SOAPElementImpl(org.apache.axiom.om.impl.dom.ElementImpl element)
Method Detail |
public void discard() throws org.apache.axiom.om.OMException
discard
in interface org.apache.axiom.om.OMNode
org.apache.axiom.om.OMException
public void internalSerialize(XMLStreamWriter writer) throws XMLStreamException
internalSerialize
in interface org.apache.axiom.om.impl.OMNodeEx
XMLStreamException
public void internalSerializeAndConsume(XMLStreamWriter writer) throws XMLStreamException
internalSerializeAndConsume
in interface org.apache.axiom.om.impl.OMNodeEx
XMLStreamException
public SOAPElement addAttribute(Name name, String value) throws SOAPException
SOAPElement
object.
addAttribute
in interface SOAPElement
name
- a Name
object with the name of the attributevalue
- a String
giving the value of the attribute
SOAPElement
object into which the attribute was
inserted
SOAPException
- if there is an error in creating the
Attributepublic SOAPElement addChildElement(Name name) throws SOAPException
addChildElement
in interface SOAPElement
SOAPException
public SOAPElement addChildElement(SOAPElement soapElement) throws SOAPException
addChildElement
in interface SOAPElement
SOAPException
public String getLocalName()
getLocalName
in interface Node
public String getNamespaceURI()
getNamespaceURI
in interface Node
public String getPrefix()
getPrefix
in interface Node
public SOAPElement addChildElement(String localName, String prefix, String uri) throws SOAPException
addChildElement
in interface SOAPElement
SOAPException
public SOAPElement addChildElement(String localName, String prefix) throws SOAPException
addChildElement
in interface SOAPElement
SOAPException
public SOAPElement addChildElement(String localName) throws SOAPException
addChildElement
in interface SOAPElement
SOAPException
public SOAPElement addNamespaceDeclaration(String prefix, String uri) throws SOAPException
addNamespaceDeclaration
in interface SOAPElement
SOAPException
public SOAPElement addTextNode(String text) throws SOAPException
Text
object initialized with the given
String
and adds it to this SOAPElement
object.
addTextNode
in interface SOAPElement
text
- a String
object with the textual content to be added
SOAPElement
object into which
the new Text
object was inserted
SOAPException
- if there is an error in creating the
new Text
objectpublic Iterator getAllAttributes()
SOAPElement
object. The iterator can be
used to get the attribute names, which can then be passed to
the method getAttributeValue
to retrieve the
value of each attribute.
getAllAttributes
in interface SOAPElement
public String getAttributeValue(Name name)
getAttributeValue
in interface SOAPElement
public Iterator getChildElements()
Text
objects as well
as SOAPElement
objects.
getChildElements
in interface SOAPElement
Text
and SOAPElement
contained within this SOAPElement
objectpublic Iterator getChildElements(Name name)
getChildElements
in interface SOAPElement
public Name getElementName()
getElementName
in interface SOAPElement
public String getEncodingStyle()
getEncodingStyle
in interface SOAPElement
public Iterator getNamespacePrefixes()
getNamespacePrefixes
in interface SOAPElement
public String getNamespaceURI(String prefix)
getNamespaceURI
in interface SOAPElement
public Iterator getVisibleNamespacePrefixes()
getVisibleNamespacePrefixes
in interface SOAPElement
public boolean removeAttribute(Name name)
removeAttribute
in interface SOAPElement
public void removeContents()
removeContents
in interface SOAPElement
public boolean removeNamespaceDeclaration(String prefix)
removeNamespaceDeclaration
in interface SOAPElement
public void setEncodingStyle(String encodingStyle) throws SOAPException
setEncodingStyle
in interface SOAPElement
SOAPException
public void setParent(org.apache.axiom.om.OMContainer parentElement)
setParent
in interface org.apache.axiom.om.impl.OMNodeEx
public String getAttribute(String name)
getAttribute
in interface Element
public Attr getAttributeNode(String name)
getAttributeNode
in interface Element
public Attr getAttributeNodeNS(String namespaceURI, String localName)
getAttributeNodeNS
in interface Element
public String getAttributeNS(String namespaceURI, String localName)
getAttributeNS
in interface Element
public NodeList getElementsByTagName(String name)
getElementsByTagName
in interface Element
public NodeList getElementsByTagNameNS(String namespaceURI, String localName)
getElementsByTagNameNS
in interface Element
public String getTagName()
getTagName
in interface Element
public boolean hasAttribute(String name)
hasAttribute
in interface Element
public boolean hasAttributeNS(String namespaceURI, String localName)
hasAttributeNS
in interface Element
public void removeAttribute(String name) throws DOMException
removeAttribute
in interface Element
DOMException
public Attr removeAttributeNode(Attr attr) throws DOMException
removeAttributeNode
in interface Element
DOMException
public void removeAttributeNS(String namespaceURI, String localName) throws DOMException
removeAttributeNS
in interface Element
DOMException
public void setAttribute(String name, String value) throws DOMException
setAttribute
in interface Element
DOMException
public Attr setAttributeNode(Attr attr) throws DOMException
setAttributeNode
in interface Element
DOMException
public Attr setAttributeNodeNS(Attr attr) throws DOMException
setAttributeNodeNS
in interface Element
DOMException
public void setAttributeNS(String namespaceURI, String qualifiedName, String value) throws DOMException
setAttributeNS
in interface Element
DOMException
public String getNodeName()
getNodeName
in interface Node
public short getNodeType()
getNodeType
in interface Node
public org.apache.axiom.om.impl.dom.ElementImpl getElement()
public SOAPElement getParentElement()
Node
object.
This method can throw an UnsupportedOperationException
if the tree is not kept in memory.
getParentElement
in interface Node
getParentElement
in class NodeImplEx
SOAPElement
object that is the parent of
this Node
object or null
if this
Node
object is root
UnsupportedOperationException
- if the whole tree is not kept in memorysetParentElement(javax.xml.soap.SOAPElement)
public void setParentElement(SOAPElement parent) throws SOAPException
NodeImplEx
Node
object to the given
SOAPElement
object.
setParentElement
in interface Node
setParentElement
in class NodeImplEx
parent
- the SOAPElement
object to be set as
the parent of this Node
object
SOAPException
- if there is a problem in setting the
parent to the given elementgetParentElement()
public Document getOwnerDocument()
getOwnerDocument
in interface Node
public String getValue()
Node
object if a child exists and its value is text.
getValue
in interface Node
getValue
in class NodeImplEx
String
with the text of the immediate child of
this Node
object if (1) there is a child and
(2) the child is a Text
object;
null
otherwisepublic Node getFirstChild()
getFirstChild
in interface Node
public Node getLastChild()
getLastChild
in interface Node
Node.getLastChild()
public Node getParentNode()
getParentNode
in interface Node
public Node getNextSibling()
getNextSibling
in interface Node
public Node getPreviousSibling()
getPreviousSibling
in interface Node
public NodeList getChildNodes()
getChildNodes
in interface Node
public boolean hasChildNodes()
hasChildNodes
in interface Node
public void setValue(String value)
setValue
in interface Node
value
- the text to set
IllegalStateException
- if the node is not a Text node and
either has more than one child node or has a child node that
is not a Text nodepublic void detachNode()
NodeImplEx
Node
object from the tree. Once
removed, this node can be garbage collected if there are no
application references to it.
detachNode
in interface Node
detachNode
in class NodeImplEx
public org.apache.axiom.om.OMNode detach()
detach
in interface org.apache.axiom.om.OMNode
detach
in class NodeImplEx
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |