|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.icl.saxon.om.AbstractNode | +--com.icl.saxon.tinytree.TinyNodeImpl | +--com.icl.saxon.tinytree.TinyParentNodeImpl | +--com.icl.saxon.tinytree.TinyElementImpl
A node in the XML parse tree representing an XML element.
This class is an implementation of NodeInfo and also implements the DOM Element interface
Fields inherited from class com.icl.saxon.tinytree.TinyNodeImpl |
document, nodeNr, parent |
Fields inherited from class com.icl.saxon.om.AbstractNode |
NODE_LETTER |
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 com.icl.saxon.om.NodeInfo |
ATTRIBUTE, COMMENT, ELEMENT, NAMESPACE, NODE, NONE, NUMBER_OF_TYPES, PI, ROOT, TEXT |
Constructor Summary | |
TinyElementImpl(TinyDocumentImpl doc,
int nodeNr)
Constructor |
Method Summary | |
void |
copy(Outputter out)
Copy this node to a given outputter (supporting xsl:copy-of) |
void |
copy(Outputter out,
boolean allNamespaces)
Copy this node to a given outputter |
java.lang.String |
getAttributeValue(int fingerprint)
Get the value of a given attribute of this node |
java.lang.String |
getAttributeValue(java.lang.String uri,
java.lang.String localName)
Find the value of a given attribute of this node. |
java.lang.String |
getBaseURI()
Get the base URI of this element node. |
short |
getNodeType()
Return the type of node. |
boolean |
hasAttributes()
Returns whether this node (if it is an element) has any attributes. |
TinyAttributeImpl |
makeAttributeNode(int index)
Make an attribute node for a given attribute of this element |
void |
outputNamespaceNodes(Outputter out,
boolean includeAncestors)
Output all namespace nodes associated with this element. |
void |
setAttribute(java.lang.String name,
java.lang.String value)
Set the value of an attribute on the current element. |
Methods inherited from class com.icl.saxon.tinytree.TinyParentNodeImpl |
copyStringValue, getStringValue, hasChildNodes |
Methods inherited from class com.icl.saxon.tinytree.TinyNodeImpl |
compareOrder, generateId, getDisplayName, getDocumentRoot, getEnumeration, getFingerprint, getLineNumber, getLocalName, getNameCode, getOriginatingNode, getParent, getPrefix, getSequenceNumber, getSystemId, getURI, isSameNode, setLineNumber, setParentNode, setSystemId |
Methods inherited from class java.lang.Object |
|
Methods inherited from interface org.w3c.dom.Element |
getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getElementsByTagName, getElementsByTagNameNS, getTagName, hasAttribute, hasAttributeNS, removeAttribute, removeAttributeNode, removeAttributeNS, setAttributeNode, setAttributeNodeNS, setAttributeNS |
Methods inherited from interface org.w3c.dom.Node |
appendChild, cloneNode, getAttributes, getChildNodes, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, hasChildNodes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue, setPrefix |
Constructor Detail |
public TinyElementImpl(TinyDocumentImpl doc, int nodeNr)
Method Detail |
public final short getNodeType()
getNodeType
in interface org.w3c.dom.Node
public java.lang.String getBaseURI()
getBaseURI
in class TinyNodeImpl
public void outputNamespaceNodes(Outputter out, boolean includeAncestors) throws javax.xml.transform.TransformerException
outputNamespaceNodes
in class TinyNodeImpl
out
- The relevant outputterincludeAncestors
- True if namespaces associated with ancestor
elements must also be output; false if these are already known to be
on the result tree.public boolean hasAttributes()
hasAttributes
in interface org.w3c.dom.Node
hasAttributes
in class TinyNodeImpl
true
if this node has any attributes,
false
otherwise.public java.lang.String getAttributeValue(java.lang.String uri, java.lang.String localName)
getAttributeValue
in class TinyNodeImpl
uri
- the namespace uri of an attributelocalName
- the local name of an attributepublic java.lang.String getAttributeValue(int fingerprint)
getAttributeValue
in class TinyNodeImpl
fingerprint
- The fingerprint of the attribute namepublic TinyAttributeImpl makeAttributeNode(int index)
index
- The relative position of the attribute, counting from zero. This
is trusted to be in range.public void setAttribute(java.lang.String name, java.lang.String value) throws org.w3c.dom.DOMException
setAttribute
in interface org.w3c.dom.Element
name
- The name of the attribute to be set. Any prefix is interpreted relative
to the namespaces defined for this element.value
- The new value of the attribute. Set this to null to remove the attribute.public void copy(Outputter out) throws javax.xml.transform.TransformerException
public void copy(Outputter out, boolean allNamespaces) throws javax.xml.transform.TransformerException
allNamespaces
- true if all namespace nodes must be copied; false
if namespace nodes for the parent element are already on the result tree
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |