org.incava.doctorj
Class MethodDocAnalyzer

java.lang.Object
  extended by org.incava.analysis.Analyzer
      extended by org.incava.doctorj.DocAnalyzer
          extended by org.incava.doctorj.ItemDocAnalyzer
              extended by org.incava.doctorj.FunctionDocAnalyzer
                  extended by org.incava.doctorj.MethodDocAnalyzer

public class MethodDocAnalyzer
extends FunctionDocAnalyzer

Analyzes Javadoc and code for methods.


Field Summary
static java.lang.String MSG_RETURN_FOR_VOID_METHOD
           
static java.lang.String MSG_RETURN_TYPE_USED
           
static java.lang.String MSG_RETURN_WITHOUT_DESCRIPTION
           
 
Fields inherited from class org.incava.doctorj.FunctionDocAnalyzer
MSG_SERIALDATA_WITHOUT_DESCRIPTION
 
Fields inherited from class org.incava.doctorj.ItemDocAnalyzer
CHKLVL_MISORDERED_TAGS, CHKLVL_SUMMARY_SENTENCE, CHKLVL_VALID_TAGS, MSG_DEPRECATED_WITHOUT_TEXT, MSG_NO_SUMMARY_SENTENCE, MSG_SEE_WITHOUT_REFERENCE, MSG_SINCE_WITHOUT_TEXT, MSG_SUMMARY_SENTENCE_DOES_NOT_END_WITH_PERIOD, MSG_SUMMARY_SENTENCE_TOO_SHORT, MSG_TAG_IMPROPER_ORDER, spellChecker
 
Fields inherited from class org.incava.doctorj.DocAnalyzer
CHKLVL_DOC_EXISTS, CHKLVL_TAG_CONTENT
 
Constructor Summary
MethodDocAnalyzer(Report r, ASTMethodDeclaration method)
           
 
Method Summary
protected  void addUndocumentedViolation(java.lang.String desc)
          Adds a violation for a method, with the violation pointing to the method name.
protected  void checkJavadoc(JavadocNode javadoc)
           
protected  SimpleNode getEnclosingNode()
          Returns the parent node, which is the enclosing declaration.
 java.lang.String getItemType()
          Returns the type of item this analyzer is operating on.
protected  ASTFormalParameters getParameterList()
          Returns the parameter list for the method.
protected  java.util.List getValidTags()
          Returns the valid tags, as strings, for methods.
 
Methods inherited from class org.incava.doctorj.ItemDocAnalyzer
addDictionary, checkForTagDescription, getJavadoc, getNode, run
 
Methods inherited from class org.incava.doctorj.DocAnalyzer
isCheckable
 
Methods inherited from class org.incava.analysis.Analyzer
addViolation, addViolation, addViolation, getReport
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MSG_RETURN_WITHOUT_DESCRIPTION

public static final java.lang.String MSG_RETURN_WITHOUT_DESCRIPTION
See Also:
Constant Field Values

MSG_RETURN_FOR_VOID_METHOD

public static final java.lang.String MSG_RETURN_FOR_VOID_METHOD
See Also:
Constant Field Values

MSG_RETURN_TYPE_USED

public static final java.lang.String MSG_RETURN_TYPE_USED
See Also:
Constant Field Values
Constructor Detail

MethodDocAnalyzer

public MethodDocAnalyzer(Report r,
                         ASTMethodDeclaration method)
Method Detail

getItemType

public java.lang.String getItemType()
Description copied from class: ItemDocAnalyzer
Returns the type of item this analyzer is operating on.

Specified by:
getItemType in class ItemDocAnalyzer

getEnclosingNode

protected SimpleNode getEnclosingNode()
Returns the parent node, which is the enclosing declaration.

Specified by:
getEnclosingNode in class ItemDocAnalyzer

checkJavadoc

protected void checkJavadoc(JavadocNode javadoc)
Overrides:
checkJavadoc in class FunctionDocAnalyzer

getParameterList

protected ASTFormalParameters getParameterList()
Returns the parameter list for the method.

Specified by:
getParameterList in class FunctionDocAnalyzer

getValidTags

protected java.util.List getValidTags()
Returns the valid tags, as strings, for methods.

Specified by:
getValidTags in class ItemDocAnalyzer

addUndocumentedViolation

protected void addUndocumentedViolation(java.lang.String desc)
Adds a violation for a method, with the violation pointing to the method name.

Specified by:
addUndocumentedViolation in class ItemDocAnalyzer