org.acm.seguin.pretty
Class JavaDocableImpl

java.lang.Object
  extended by org.acm.seguin.pretty.JavaDocableImpl
All Implemented Interfaces:
JavaDocable

public class JavaDocableImpl
extends java.lang.Object
implements JavaDocable

Stores the java doc components

Author:
Chris Seguin, Mike Atkinson

Constructor Summary
JavaDocableImpl()
          Constructor
 
Method Summary
 void addJavaDocComponent(JavaDocComponent component)
          Allows you to add a java doc component
 boolean contains(java.lang.String type)
          Contains a particular item
 boolean contains(java.lang.String type, java.lang.String id)
          Contains a particular item
 void finish()
          Makes sure all the java doc components are present
 boolean isPrinted()
          Determines if the javadoc comments were printed
 boolean isRequired()
          Checks to see if it was printed
 void printJavaDocComponents(PrintData printData)
          Prints all the java doc components
 void printJavaDocComponents(PrintData printData, java.lang.String order)
          Prints all the java doc components
 void require(java.lang.String tag, java.lang.String descr)
          Make a required field
 void require(java.lang.String tag, java.lang.String id, java.lang.String descr)
          Make a required field
 void sort(java.lang.String type, java.lang.String[] names)
          Allows you to sort the javadoc tags.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaDocableImpl

public JavaDocableImpl()
Constructor

Method Detail

isRequired

public boolean isRequired()
Checks to see if it was printed

Specified by:
isRequired in interface JavaDocable
Returns:
true if it still needs to be printed

isPrinted

public boolean isPrinted()
Determines if the javadoc comments were printed

Returns:
The Printed value

addJavaDocComponent

public void addJavaDocComponent(JavaDocComponent component)
Allows you to add a java doc component

Specified by:
addJavaDocComponent in interface JavaDocable
Parameters:
component - the component that can be added

sort

public void sort(java.lang.String type,
                 java.lang.String[] names)
Allows you to sort the javadoc tags.

Parameters:
type - The "@"tag to sort (e.g. "@param").
names - The order of identifies desired after sort (e.g. for this method {"type", "names"} ).
Since:
JRefactory 2.7.00

printJavaDocComponents

public void printJavaDocComponents(PrintData printData)
Prints all the java doc components

Specified by:
printJavaDocComponents in interface JavaDocable
Parameters:
printData - the print data

printJavaDocComponents

public void printJavaDocComponents(PrintData printData,
                                   java.lang.String order)
Prints all the java doc components

Parameters:
printData - the print data
order - the order for the tags

finish

public void finish()
Makes sure all the java doc components are present

Specified by:
finish in interface JavaDocable

contains

public boolean contains(java.lang.String type)
Contains a particular item

Parameters:
type - the type we are looking for
Returns:
true if we found a tag with that name

contains

public boolean contains(java.lang.String type,
                        java.lang.String id)
Contains a particular item

Parameters:
type - the type we are looking for
id - the id
Returns:
Description of the Returned Value

require

public void require(java.lang.String tag,
                    java.lang.String descr)
Make a required field

Parameters:
tag - the tag
descr - the default description

require

public void require(java.lang.String tag,
                    java.lang.String id,
                    java.lang.String descr)
Make a required field

Parameters:
tag - the tag
id - the id
descr - the default description