org.htmlparser.nodes
Class RemarkNode
- Cloneable, Node, Remark, Serializable
The remark tag is identified and represented by this class.
protected String | mText - The contents of the remark node, or override text.
|
RemarkNode(String text) - Constructor takes in the text string.
|
RemarkNode(Page page, int start, int end) - Constructor takes in the page and beginning and ending posns.
|
void | accept(NodeVisitor visitor) - Remark visiting code.
|
String | getText() - Returns the text contents of the comment tag.
|
void | setText(String text) - Sets the string contents of the node.
|
String | toHtml(boolean verbatim) - Return The full HTML remark.
|
String | toPlainTextString() - Return the remark text.
|
String | toString() - Print the contents of the remark tag.
|
accept , clone , collectInto , doSemanticAction , getChildren , getEndPosition , getFirstChild , getLastChild , getNextSibling , getPage , getParent , getPreviousSibling , getStartPosition , getText , setChildren , setEndPosition , setPage , setParent , setStartPosition , setText , toHtml , toHtml , toPlainTextString , toString |
mText
protected String mText
The contents of the remark node, or override text.
RemarkNode
public RemarkNode(String text)
Constructor takes in the text string.
text
- The string node text. For correct generation of HTML, this
should not contain representations of tags (unless they are balanced).
RemarkNode
public RemarkNode(Page page,
int start,
int end)
Constructor takes in the page and beginning and ending posns.
page
- The page this remark is on.start
- The beginning position of the remark.end
- The ending positiong of the remark.
getText
public String getText()
Returns the text contents of the comment tag.
- getText in interface Remark
- getText in interface Node
- getText in interface AbstractNode
- The contents of the text inside the comment delimiters.
setText
public void setText(String text)
Sets the string contents of the node.
If the text has the remark delimiters (<!-- -->), these are stripped off.
- setText in interface Remark
- setText in interface Node
- setText in interface AbstractNode
text
- The new text for the node.
toHtml
public String toHtml(boolean verbatim)
Return The full HTML remark.
- toHtml in interface Node
- toHtml in interface AbstractNode
verbatim
- If true
return as close to the original
page text as possible.
toString
public String toString()
Print the contents of the remark tag.
This is suitable for display in a debugger or output to a printout.
Control characters are replaced by their equivalent escape
sequence and contents is truncated to 80 characters.
- toString in interface Node
- toString in interface AbstractNode
- A string representation of the remark node.
| © 2005 Derrick Oswald Mai 08, 2008 |
HTML Parser is an open source library released under LGPL. |  |