Class QueueableWithoutFinalizerRule
-
- All Implemented Interfaces:
-
net.sourceforge.pmd.lang.apex.ast.ApexVisitor
,net.sourceforge.pmd.lang.ast.AstVisitor
,net.sourceforge.pmd.lang.rule.Rule
,net.sourceforge.pmd.properties.PropertySource
public class QueueableWithoutFinalizerRule extends AbstractApexRule
Scans classes which implement the `Queueable` interface. If the `public void execute(QueueableContext context)` method does not call the `System.attachFinalizer(Finalizer f)` method, then a violation will be added to the `execute` method.
mitchspano
-
-
Field Summary
Fields Modifier and Type Field Description public Language
language
public LanguageVersion
minimumLanguageVersion
public LanguageVersion
maximumLanguageVersion
public String
name
public String
since
public String
ruleClass
public String
ruleSetName
public String
message
public String
description
public List<String>
examples
public String
externalInfoUrl
public RulePriority
priority
public final List<PropertyDescriptor<out Object>>
propertyDescriptors
public final static PropertyDescriptor<Optional<Pattern>>
VIOLATION_SUPPRESS_REGEX_DESCRIPTOR
public final static PropertyDescriptor<Optional<String>>
VIOLATION_SUPPRESS_XPATH_DESCRIPTOR
-
Constructor Summary
Constructors Constructor Description QueueableWithoutFinalizerRule()
-
Method Summary
Modifier and Type Method Description Object
visit(ASTUserClass theClass, Object data)
If the class implements the `Queueable` interface and the `execute(QueueableContext context)` does not call the `System.attachFinalizer(Finalizer f)` method, then add a violation. -
Methods inherited from class net.sourceforge.pmd.lang.rule.AbstractRule
addExample, deepCopy, end, equals, getDescription, getExamples, getExternalInfoUrl, getLanguage, getMaximumLanguageVersion, getMessage, getMinimumLanguageVersion, getName, getPriority, 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 net.sourceforge.pmd.lang.apex.rule.AbstractApexRule
apply, visitNode
-
Methods inherited from class net.sourceforge.pmd.lang.apex.ast.ApexVisitor
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, visitApexNode
-
Methods inherited from class net.sourceforge.pmd.lang.rule.Rule
apply, initialize
-
Methods inherited from class net.sourceforge.pmd.properties.PropertySource
dysfunctionReason
-
Methods inherited from class net.sourceforge.pmd.lang.ast.AstVisitor
cannotVisit, visitNode
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
visit
Object visit(ASTUserClass theClass, Object data)
If the class implements the `Queueable` interface and the `execute(QueueableContext context)` does not call the `System.attachFinalizer(Finalizer f)` method, then add a violation.
-
-
-
-