|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.generationjava.io.xml.XMLNode
An xml tag. It can be a processing instructon, an empty tag or a normal tag. Currently, if the tag is inside a namespace then that is a part of the name. That is, all names of tags are fully qualified by the namespace.
| Constructor Summary | |
XMLNode()
Empty Constructor. |
|
XMLNode(String name)
Create a new node with this name. |
|
| Method Summary | |
void |
addAttr(String name,
String value)
Add an attribute with specified name and value. |
void |
addNode(XMLNode node)
Add a child node to this node. |
String |
bodyToString()
Get the String version of the body of this tag. |
Enumeration |
enumerateAttr()
Enumerate over all the attributes of this node. |
Enumeration |
enumerateNode()
Enumerate over all of this node's children nodes. |
Enumeration |
enumerateNode(String name)
|
String |
getAttr(String name)
Get the attribute with the specified name. |
String |
getName()
Get the name of this node. |
String |
getNamespace()
Get the namespace of this node. |
XMLNode |
getNode(String name)
Get the node with the specified name. |
String |
getTagName()
Get the tag name of this node. |
String |
getValue()
Get the appended toString's of the children of this node. |
boolean |
isComment()
Is it a comment |
boolean |
isDocType()
Is it a doctype |
boolean |
isEmpty()
Is this node empty. |
boolean |
isInvisible()
Is it invisible |
boolean |
isPI()
Is it a processing instruction |
boolean |
isTag()
Is this a normal tag? That is, not plaintext, not comment and not a pi. |
boolean |
isTextNode()
Is this a text node. |
void |
setComment(boolean b)
Set whether this node is a comment or not. |
void |
setDocType(boolean b)
Set whether this node is a doctype or not. |
void |
setInvisible(boolean b)
Set whether this node is invisible or not. |
void |
setPI(boolean b)
Set whether this node is a processing instruction or not. |
void |
setPlaintext(String str)
Set the plaintext contained in this node. |
String |
toString()
Turn this node into a String. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public XMLNode()
public XMLNode(String name)
| Method Detail |
public void addNode(XMLNode node)
public Enumeration enumerateNode(String name)
public void addAttr(String name,
String value)
public String getAttr(String name)
public Enumeration enumerateAttr()
public XMLNode getNode(String name)
public Enumeration enumerateNode()
public String getName()
public String getNamespace()
public String getTagName()
public String getValue()
public void setPlaintext(String str)
public boolean isTag()
public boolean isInvisible()
public void setInvisible(boolean b)
public boolean isDocType()
public void setDocType(boolean b)
public boolean isComment()
public void setComment(boolean b)
public boolean isPI()
public void setPI(boolean b)
public boolean isEmpty()
public boolean isTextNode()
public String toString()
public String bodyToString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||