org.sourceflow.c
Class CComment

java.lang.Object
  extended byorg.sourceflow.CodeElement
      extended byorg.sourceflow.c.CComment
All Implemented Interfaces:
java.lang.Comparable

public class CComment
extends CodeElement

A class generating a C comment.


Constructor Summary
CComment(java.lang.String comment)
          Creates a new comment.
 
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 org.sourceflow.CodeElement
compareTo, printSeparator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CComment

public CComment(java.lang.String comment)
Creates a new comment.

Parameters:
comment - the comment text
Method Detail

category

public int category()
Returns a numeric category number for the code element. A lower category number implies that the code element should be placed before code elements with a higher category number within a declaration.

Specified by:
category in class CodeElement
Returns:
the category number

print

public void print(java.io.PrintWriter out,
                  CodeStyle style,
                  int indent)
Prints the code element to the specified output stream.

Specified by:
print in class CodeElement
Parameters:
out - the output stream
style - the code style to use
indent - the indentation level