gnu.xml.dom
Class DomComment
java.lang.Object
|
+--gnu.xml.dom.DomNode
|
+--gnu.xml.dom.DomCharacterData
|
+--gnu.xml.dom.DomComment
All Implemented Interfaces:
java.lang.Cloneable, CharacterData, Comment, DocumentEvent, EventTarget, Node, NodeList
"Comment" implementation.
Comments hold data intended for direct consumption by people;
programs should only use ProcessingInstruction nodes. Note that
since SAX makes comment reporting optional, XML systems that
rely on comments (such as by using this class) will often lose
those comments at some point in the processing pipeline.
- David Brownell
DomComment
protected DomComment(Document owner, java.lang.String value)
Constructs a comment node associated with the specified
document and holding the specified data.
This constructor should only be invoked by a Document as part of
its createComment functionality, or through a subclass which is
similarly used in a "Sub-DOM" style layer.
- owner
- value
getNodeName
public final String getNodeName()
DOM L1
Returns the string "#comment".
getNodeType
public final short getNodeType()
DOM L1
Returns the constant COMMENT_NODE.