| simple.page.translate.Parser simple.page.translate.Token simple.page.translate.Comment
Comment | class Comment extends Token (Code) | | The Comment object is used to parse a JSP comment.
This performs a very simple parsing of the JSP comment provided.
This is parsed so that it can be included into the source.
<%-- comment --%>
The above expression is parsed an inserted into the JSP source
as an embedded comment starting with "/*" comment tag.
author: Niall Gallagher |
Constructor Summary | |
public | Comment() Constructor for the Comment token. | public | Comment(String token) Constructor for the Comment token. |
Method Summary | |
protected void | init() This will clear the comment token so that the parse can be reused
by the builder. | protected void | parse() This is a very simple parse method which basically extracts the
begining and end values from the token. | public void | process(Definition source, Builder builder) This method will supply code to the document definition that
will allow a comment to be printed by the page. |
Comment | public Comment()(Code) | | Constructor for the Comment token. This will
create a buffer, which can be used to accumulate the data
extracted from the supplied print token.
|
Comment | public Comment(String token)(Code) | | Constructor for the Comment token. This will
create a buffer, which can be used to accumulate the data
extracted from the supplied print token before parsing.
Parameters: token - this is the insert token to be parsed |
init | protected void init()(Code) | | This will clear the comment token so that the parse can be reused
by the builder. In practice this method just satisfies the
contract of the token so that this object is not abstract.
|
parse | protected void parse()(Code) | | This is a very simple parse method which basically extracts the
begining and end values from the token. For instance this will
remove "<%--" and "--%>" from the token supplied.
|
process | public void process(Definition source, Builder builder)(Code) | | This method will supply code to the document definition that
will allow a comment to be printed by the page. The data
inserted into the definition will be displayed in the body.
Parameters: source - this is the source to push the code into Parameters: builder - this is the builder driving the process |
|
|