|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.enhydra.xml.xmlc.XMLCUtil
Utility methods for dealing with DOMs.
Field Summary | |
static int |
PRINT_ALL
Deprecated. Use DOMInfo |
static int |
PRINT_CDATA
Deprecated. Use DOMInfo |
static int |
PRINT_COMMENT
Deprecated. Use DOMInfo |
static int |
PRINT_DEFAULT
Deprecated. Use DOMInfo |
static int |
PRINT_DOCUMENTTYPE
Deprecated. Use DOMInfo |
static int |
PRINT_TEXT
Deprecated. Use DOMInfo |
Constructor Summary | |
XMLCUtil()
|
Method Summary | |
static org.w3c.dom.Node |
copyNode(org.w3c.dom.Node srcNode,
org.w3c.dom.Document destDocument)
Deprecated. use org.w3c.dom.Document.importNode |
static org.w3c.dom.Text |
findFirstText(org.w3c.dom.Node node)
Find the first text descendent node of an element. |
static org.w3c.dom.Attr |
getAttributeByName(org.w3c.dom.Node node,
java.lang.String name)
Deprecated. use org.w3c.dom.Element.getAttributeNode |
static org.w3c.dom.Element |
getElementById(java.lang.String id,
org.w3c.dom.Node node)
Recursively search for an element by id starting at a node. |
static org.w3c.dom.Text |
getFirstText(org.w3c.dom.Node node)
Find the first text descendent node of an element. |
static org.w3c.dom.Element |
getRequiredElementById(java.lang.String id,
org.w3c.dom.Node node)
Recursively search for an required element by id starting at a node. |
static void |
printNode(java.lang.String msg,
org.w3c.dom.Node node,
int options,
java.io.PrintWriter out)
Deprecated. Use DOMInfo |
static void |
printNode(java.lang.String msg,
org.w3c.dom.Node node,
java.io.OutputStream out)
Deprecated. Use DOMInfo |
static void |
printNode(java.lang.String msg,
org.w3c.dom.Node node,
java.io.PrintWriter out)
Deprecated. Use DOMInfo |
static org.w3c.dom.Node |
replaceNode(org.w3c.dom.Node srcNode,
org.w3c.dom.Node destNode)
Deprecated. use org.enhydra.xml.dom.DOMOps#replaceNode |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int PRINT_COMMENT
DOMInfo.printTree(java.lang.String, org.w3c.dom.Node, int, java.io.PrintWriter)
,
Constant Field Valuespublic static final int PRINT_TEXT
DOMInfo.printTree(java.lang.String, org.w3c.dom.Node, int, java.io.PrintWriter)
,
Constant Field Valuespublic static final int PRINT_CDATA
Option to printNode to print the contents of Text nodes.
,
Constant Field Valuespublic static final int PRINT_DOCUMENTTYPE
Option to printNode to print the contents of DocumentType nodes.
,
Constant Field Valuespublic static final int PRINT_ALL
All Print options.
,
Constant Field Valuespublic static final int PRINT_DEFAULT
Default print options.
,
Constant Field ValuesConstructor Detail |
public XMLCUtil()
Method Detail |
public static org.w3c.dom.Attr getAttributeByName(org.w3c.dom.Node node, java.lang.String name)
node
- Node who's attribute is desired.name
- The name of the desired attribute.
Element.getAttributeNode
public static org.w3c.dom.Text findFirstText(org.w3c.dom.Node node)
node
- The starting node for the search.
public static org.w3c.dom.Text getFirstText(org.w3c.dom.Node node)
node
- The starting node for the search.
XMLCError
- If a text node was not found.public static org.w3c.dom.Element getElementById(java.lang.String id, org.w3c.dom.Node node)
id
- The element id to find. Case is ignored.node
- The node to start the search at.
public static org.w3c.dom.Element getRequiredElementById(java.lang.String id, org.w3c.dom.Node node)
id
- The element id to find. Case is ignored.node
- The node to start the search at.
XMLCError
- Thrown if the element is not found.getElementById(java.lang.String, org.w3c.dom.Node)
public static org.w3c.dom.Node copyNode(org.w3c.dom.Node srcNode, org.w3c.dom.Document destDocument)
srcNode
- The node to copy.destDocument
- The destination document. The node will
belong to this document but will not be inserted in it.
Document.importNode(org.w3c.dom.Node, boolean)
public static org.w3c.dom.Node replaceNode(org.w3c.dom.Node srcNode, org.w3c.dom.Node destNode)
DOMOps.replaceNode(org.w3c.dom.Node, org.w3c.dom.Node)
public static void printNode(java.lang.String msg, org.w3c.dom.Node node, int options, java.io.PrintWriter out)
DOMInfo.printTree(java.lang.String, org.w3c.dom.Node, int, java.io.PrintWriter)
public static void printNode(java.lang.String msg, org.w3c.dom.Node node, java.io.PrintWriter out)
DOMInfo.printTree(java.lang.String, org.w3c.dom.Node, int, java.io.PrintWriter)
public static void printNode(java.lang.String msg, org.w3c.dom.Node node, java.io.OutputStream out)
DOMInfo.printTree(java.lang.String, org.w3c.dom.Node, int, java.io.PrintWriter)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |