|
SienaXML (v.2.0.0) API documentation | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsiena.xml.DOMTreeProcessing
public class DOMTreeProcessing
This class is used to handle different types of processing of the XML DOM tree generated from the DOMParserWrapper.
Constructor Summary | |
---|---|
DOMTreeProcessing()
|
Method Summary | |
---|---|
static int |
countSameAttributeValueSiblings(org.w3c.dom.Node node,
java.lang.String targetAttr)
Count the number of siblings that have the same attribute as the node passed in. |
static int |
countSameTagSiblings(org.w3c.dom.Node node)
This method will return a count of the number of nodes that have the same tag as the node that was passed in. |
static int |
countSiblingsWithTag(org.w3c.dom.Node node,
java.lang.String tagName)
This function will count the number of siblings to the node passed in that have the same tag name as the one contained in the string. |
static org.w3c.dom.Node |
createNode(java.lang.String name,
java.lang.String value)
Create a node with the name name and with the value value |
static org.w3c.dom.Node |
createNode(java.lang.String name,
java.lang.String value,
java.lang.String namespace)
Create a node that has the name name, value of value>, in the namespace namespace |
static org.w3c.dom.Node |
findChildByName(java.lang.String name,
org.w3c.dom.Node node)
This function will find a child node of the node passed in based on the name given it as an arguement. |
static java.lang.String |
getNodeValue(org.w3c.dom.Node node)
This method will get the value for the xml tag represented by the node passed in. |
static void |
setValue(org.w3c.dom.Node node,
java.lang.String value)
This sets the value for a node to value |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DOMTreeProcessing()
Method Detail |
---|
public static org.w3c.dom.Node findChildByName(java.lang.String name, org.w3c.dom.Node node)
name
- The name of the child node to look fornode
- The node to use as the parent node.
public static int countSameTagSiblings(org.w3c.dom.Node node)
node
- Node to use as the basis of search, both for the tag name and the level in the DOM tree to look at
public static int countSiblingsWithTag(org.w3c.dom.Node node, java.lang.String tagName)
node
- This is the node used as the reference point for the search.tagName
- This is the name of the tag being looked for
public static java.lang.String getNodeValue(org.w3c.dom.Node node)
node
- The node to get the value for
public static int countSameAttributeValueSiblings(org.w3c.dom.Node node, java.lang.String targetAttr)
node
- The reference Node that determines the attribute value and what nodes to look at (its siblings)targetAttr
- The name of the attribute to look for in the sibling nodes
public static org.w3c.dom.Node createNode(java.lang.String name, java.lang.String value)
name
- The name that the new Node should havevalue
- The value that the new Node should have
public static org.w3c.dom.Node createNode(java.lang.String name, java.lang.String value, java.lang.String namespace)
name
- Name of the new Nodevalue
- Value of the new Nodenamespace
- Namespace which the node should be in
public static void setValue(org.w3c.dom.Node node, java.lang.String value)
node
- The Node object to change the value ofvalue
- The new value to assign to the Node
|
SienaXML (v.2.0.0) API documentation | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |