|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.percederberg.grammatica.code.CodeElement | +--net.percederberg.grammatica.code.java.JavaComment
A class generating a Java comment.
Field Summary | |
static int |
BLOCK
The block comment type. |
static int |
DOCUMENTATION
The JavaDoc documentation comment type. |
static int |
SINGLELINE
The single line comment type. |
Constructor Summary | |
JavaComment(int type,
java.lang.String comment)
Creates a new comment of the specified type. |
|
JavaComment(java.lang.String comment)
Creates a new documentation comment with no indentation. |
Method Summary | |
int |
category()
Returns a numeric category number for the code element. |
void |
print(java.io.PrintWriter out,
CodeStyle style,
int indent)
Prints the code element to the specified output stream. |
Methods inherited from class net.percederberg.grammatica.code.CodeElement |
compareTo |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int DOCUMENTATION
public static final int BLOCK
public static final int SINGLELINE
Constructor Detail |
public JavaComment(java.lang.String comment)
comment
- the comment textpublic JavaComment(int type, java.lang.String comment)
type
- the comment typecomment
- the comment textDOCUMENTATION
,
BLOCK
,
SINGLELINE
Method Detail |
public int category()
category
in class CodeElement
public void print(java.io.PrintWriter out, CodeStyle style, int indent)
print
in class CodeElement
out
- the output streamstyle
- the code style to useindent
- the indentation level
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |