Package com.pd4ml.dom
Class Comment
- java.lang.Object
-
- com.pd4ml.dom.Node
-
- com.pd4ml.dom.Comment
-
public class Comment extends Node
An HTML comment.- Since:
- v4.2.0
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetData()java.lang.StringgetTextContent()Comments contribute no text: always an empty string.voidsetData(java.lang.String data)voidsetTextContent(java.lang.String text)Replaces the content of this node with the text: an element's children are replaced by one text node (none for an empty text); a text or comment gets the text as its data.-
Methods inherited from class com.pd4ml.dom.Node
appendChild, cloneNode, contains, equals, getChildNodes, getFirstChild, getLastChild, getNextSibling, getNodeName, getOwnerDocument, getParentElement, getParentNode, getPreviousSibling, hasChildNodes, hashCode, insertBefore, remove, removeChild, replaceChild, toHtml, toString
-
-
-
-
Method Detail
-
getData
public java.lang.String getData()
-
setData
public void setData(java.lang.String data)
-
getTextContent
public java.lang.String getTextContent()
Comments contribute no text: always an empty string. UsegetData().- Overrides:
getTextContentin classNode
-
setTextContent
public void setTextContent(java.lang.String text)
Description copied from class:NodeReplaces the content of this node with the text: an element's children are replaced by one text node (none for an empty text); a text or comment gets the text as its data.- Overrides:
setTextContentin classNode
-
-