Class AbstractJavaRule
- java.lang.Object
-
- net.sourceforge.pmd.properties.AbstractPropertySource
-
- net.sourceforge.pmd.lang.rule.AbstractRule
-
- net.sourceforge.pmd.lang.java.rule.AbstractJavaRule
-
- All Implemented Interfaces:
net.sourceforge.pmd.lang.ast.AstVisitor
,JavaVisitor
,net.sourceforge.pmd.lang.rule.Rule
,net.sourceforge.pmd.properties.PropertySource
- Direct Known Subclasses:
net.sourceforge.pmd.lang.java.rule.internal.AbstractIgnoredAnnotationRule
,AbstractJavaRulechainRule
,AvoidDeeplyNestedIfStmtsRule
,AvoidReassigningCatchVariablesRule
,CheckResultSetRule
,CloseResourceRule
,ConsecutiveAppendsShouldReuseRule
,CouplingBetweenObjectsRule
,DoubleCheckedLockingRule
,LawOfDemeterRule
,LoosePackageCouplingRule
,StringInstantiationRule
,UnnecessaryImportRule
,UnusedLocalVariableRule
,UselessStringValueOfRule
public abstract class AbstractJavaRule extends net.sourceforge.pmd.lang.rule.AbstractRule implements JavaVisitor
Base class for Java rules. Any rule written in Java to analyse Java source should extend from this base class. TODO add documentation
-
-
Constructor Summary
Constructors Constructor Description AbstractJavaRule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply(net.sourceforge.pmd.lang.ast.Node target, net.sourceforge.pmd.reporting.RuleContext ctx)
Object
visitNode(net.sourceforge.pmd.lang.ast.Node node, Object param)
-
Methods inherited from class net.sourceforge.pmd.lang.rule.AbstractRule
addExample, asCtx, buildTargetSelector, deepCopy, end, equals, getDescription, getExamples, getExternalInfoUrl, getLanguage, getMaximumLanguageVersion, getMessage, getMinimumLanguageVersion, getName, getPriority, getPropertySourceType, getRuleClass, getRuleSetName, getSince, getTargetSelector, hashCode, isDeprecated, setDeprecated, setDescription, setExternalInfoUrl, setLanguage, setMaximumLanguageVersion, setMessage, setMinimumLanguageVersion, setName, setPriority, setRuleClass, setRuleSetName, setSince, start
-
Methods inherited from class net.sourceforge.pmd.properties.AbstractPropertySource
definePropertyDescriptor, getOverriddenPropertiesByPropertyDescriptor, getOverriddenPropertyDescriptors, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, isPropertyOverridden, setProperty
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sourceforge.pmd.lang.java.ast.JavaVisitor
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, visitJavaNode
-
Methods inherited from interface net.sourceforge.pmd.properties.PropertySource
definePropertyDescriptor, dysfunctionReason, getOverriddenPropertiesByPropertyDescriptor, getOverriddenPropertyDescriptors, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, isPropertyOverridden, setProperty
-
-
-
-
Method Detail
-
visitNode
public Object visitNode(net.sourceforge.pmd.lang.ast.Node node, Object param)
- Specified by:
visitNode
in interfacenet.sourceforge.pmd.lang.ast.AstVisitor
-
apply
public void apply(net.sourceforge.pmd.lang.ast.Node target, net.sourceforge.pmd.reporting.RuleContext ctx)
- Specified by:
apply
in interfacenet.sourceforge.pmd.lang.rule.Rule
-
-