Class CommentContentRule
- java.lang.Object
-
- net.sourceforge.pmd.properties.AbstractPropertySource
-
- net.sourceforge.pmd.lang.rule.AbstractRule
-
- net.sourceforge.pmd.lang.java.rule.AbstractJavaRule
-
- net.sourceforge.pmd.lang.java.rule.documentation.AbstractCommentRule
-
- net.sourceforge.pmd.lang.java.rule.documentation.CommentContentRule
-
- All Implemented Interfaces:
JavaParserVisitor
,ImmutableLanguage
,PropertySource
,Rule
public class CommentContentRule extends AbstractCommentRule
A rule that checks for illegal words in the comment text. TODO implement regex option- Author:
- Brian Remedios
-
-
Field Summary
Fields Modifier and Type Field Description static PropertyDescriptor<Boolean>
CASE_SENSITIVE_DESCRIPTOR
static PropertyDescriptor<List<String>>
DISSALLOWED_TERMS_DESCRIPTOR
-
Fields inherited from class net.sourceforge.pmd.properties.AbstractPropertySource
propertyDescriptors, propertyValuesByDescriptor
-
Fields inherited from interface net.sourceforge.pmd.Rule
VIOLATION_SUPPRESS_REGEX_DESCRIPTOR, VIOLATION_SUPPRESS_XPATH_DESCRIPTOR
-
-
Constructor Summary
Constructors Constructor Description CommentContentRule()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description String
dysfunctionReason()
void
end(RuleContext ctx)
.boolean
hasDissallowedTerms()
Deprecated.void
start(RuleContext ctx)
Capture values and perform all the case-conversions once per runObject
visit(ASTCompilationUnit cUnit, Object data)
-
Methods inherited from class net.sourceforge.pmd.lang.java.rule.documentation.AbstractCommentRule
assignCommentsToDeclarations, filteredCommentIn, orderedCommentsAndDeclarations, tagsIndicesIn
-
Methods inherited from class net.sourceforge.pmd.lang.java.rule.AbstractJavaRule
apply, getDeclaringType, importsPackage, isQualifiedName, isSuppressed, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visitAll
-
Methods inherited from class net.sourceforge.pmd.lang.rule.AbstractRule
addExample, addRuleChainVisit, addRuleChainVisit, addViolation, addViolation, addViolation, addViolationWithMessage, addViolationWithMessage, addViolationWithMessage, deepCopy, deepCopyValuesTo, equals, getDescription, getExamples, getExternalInfoUrl, getLanguage, getMaximumLanguageVersion, getMessage, getMinimumLanguageVersion, getName, getParserOptions, getPriority, getPropertySourceType, getRuleChainVisits, getRuleClass, getRuleSetName, getSince, hashCode, isDeprecated, isDfa, isMultifile, isRuleChain, isTypeResolution, setDeprecated, setDescription, setDfa, setExternalInfoUrl, setLanguage, setMaximumLanguageVersion, setMessage, setMinimumLanguageVersion, setMultifile, setName, setPriority, setRuleClass, setRuleSetName, setSince, setTypeResolution, setUsesDFA, setUsesMultifile, setUsesTypeResolution, usesDFA, usesMultifile, usesRuleChain, usesTypeResolution
-
Methods inherited from class net.sourceforge.pmd.properties.AbstractPropertySource
copyPropertyDescriptors, copyPropertyValues, definePropertyDescriptor, getOverriddenPropertiesByPropertyDescriptor, getOverriddenPropertyDescriptors, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, isPropertyOverridden, setProperty, setProperty, useDefaultValueFor, usesDefaultValues
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sourceforge.pmd.properties.PropertySource
definePropertyDescriptor, getOverriddenPropertiesByPropertyDescriptor, getOverriddenPropertyDescriptors, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, isPropertyOverridden, setProperty, setProperty, useDefaultValueFor, usesDefaultValues
-
-
-
-
Field Detail
-
CASE_SENSITIVE_DESCRIPTOR
public static final PropertyDescriptor<Boolean> CASE_SENSITIVE_DESCRIPTOR
-
DISSALLOWED_TERMS_DESCRIPTOR
public static final PropertyDescriptor<List<String>> DISSALLOWED_TERMS_DESCRIPTOR
-
-
Method Detail
-
start
public void start(RuleContext ctx)
Capture values and perform all the case-conversions once per run- Specified by:
start
in interfaceRule
- Overrides:
start
in classAbstractRule
-
end
public void end(RuleContext ctx)
.- Specified by:
end
in interfaceRule
- Overrides:
end
in classAbstractRule
- See Also:
Rule.end(RuleContext)
-
visit
public Object visit(ASTCompilationUnit cUnit, Object data)
- Specified by:
visit
in interfaceJavaParserVisitor
- Overrides:
visit
in classAbstractJavaRule
-
hasDissallowedTerms
@Deprecated public boolean hasDissallowedTerms()
Deprecated.
-
dysfunctionReason
public String dysfunctionReason()
- Specified by:
dysfunctionReason
in interfacePropertySource
- Overrides:
dysfunctionReason
in classAbstractPropertySource
- See Also:
PropertySource.dysfunctionReason()
-
-