Modifier and Type | Method | Description |
---|---|---|
void |
Rule.addRuleChainVisit(java.lang.Class<? extends Node> nodeClass) |
Adds an AST node by class to be visited by the Rule on the RuleChain.
|
void |
Rule.apply(java.util.List<? extends Node> nodes,
RuleContext ctx) |
Apply this rule to the given collection of nodes, using the given
context.
|
void |
RuleChain.apply(java.util.List<Node> nodes,
RuleContext ctx,
Language language) |
Apply the RuleChain to the given Nodes using the given RuleContext, for
those rules using the given Language.
|
void |
RuleSet.apply(java.util.List<? extends Node> acuList,
RuleContext ctx) |
Executes the rules in this ruleset against each of the given nodes.
|
void |
RuleSets.apply(java.util.List<Node> acuList,
RuleContext ctx,
Language language) |
Apply all applicable rules to the compilation units.
|
Modifier and Type | Method | Description |
---|---|---|
Node |
Parser.parse(java.lang.String fileName,
java.io.Reader source) |
Parse source code and return the root node of the AST.
|
Modifier and Type | Method | Description |
---|---|---|
java.lang.Class<? extends Node> |
DataFlowHandler.getLabelStatementNodeClass() |
Modifier and Type | Method | Description |
---|---|---|
DataFlowNode |
DataFlowHandler.createDataFlowNode(java.util.List<DataFlowNode> dataFlow,
Node node) |
|
void |
VisitorStarter.start(Node rootNode) |
Start the visitor, given the root-node of the AST.
|
Modifier and Type | Interface | Description |
---|---|---|
interface |
QualifiableNode |
Nodes that can be described with a qualified name.
|
interface |
SignedNode<N> |
Nodes that can be described by a signature.
|
Modifier and Type | Class | Description |
---|---|---|
class |
AbstractNode |
Base class for all implementations of the Node interface.
|
Modifier and Type | Field | Description |
---|---|---|
protected Node[] |
AbstractNode.children |
|
protected Node |
AbstractNode.parent |
Modifier and Type | Method | Description |
---|---|---|
Node |
AbstractNode.getNthParent(int n) |
|
Node |
Node.getNthParent(int n) |
Returns the n-th parent or null if there are not
n ancestors |
Node |
AbstractNode.jjtGetChild(int index) |
|
Node |
Node.jjtGetChild(int index) |
This method returns a child node.
|
Node |
AbstractNode.jjtGetParent() |
|
Node |
Node.jjtGetParent() |
Returns the parent of this node.
|
Modifier and Type | Method | Description |
---|---|---|
java.util.List<Node> |
AbstractNode.findChildNodesWithXPath(java.lang.String xpathString) |
|
java.util.List<? extends Node> |
Node.findChildNodesWithXPath(java.lang.String xpathString) |
Returns all the nodes matching the xpath expression.
|
Modifier and Type | Method | Description |
---|---|---|
void |
AbstractNode.jjtAddChild(Node child,
int index) |
|
void |
Node.jjtAddChild(Node child,
int index) |
This method tells the node to add its argument to the node's list of
children.
|
void |
AbstractNode.jjtSetParent(Node parent) |
|
void |
Node.jjtSetParent(Node parent) |
Sets the parent of this node.
|
Modifier and Type | Method | Description |
---|---|---|
protected Node |
NodeIterator.getFirstChild(Node contextNode) |
|
protected abstract Node |
NodeIterator.getFirstNode(Node contextNode) |
|
protected Node |
NodeIterator.getLastChild(Node contextNode) |
|
protected abstract Node |
NodeIterator.getNextNode(Node contextNode) |
|
protected Node |
NodeIterator.getNextSibling(Node contextNode) |
|
Node |
Attribute.getParent() |
|
protected Node |
NodeIterator.getPreviousSibling(Node contextNode) |
|
Node |
NodeIterator.next() |
Modifier and Type | Method | Description |
---|---|---|
java.util.Iterator<Node> |
DocumentNavigator.getChildAxisIterator(java.lang.Object contextNode) |
Get an iterator over all of this node's children.
|
java.util.Iterator<Node> |
DocumentNavigator.getFollowingAxisIterator(java.lang.Object contextNode) |
Get an iterator over all following nodes, depth-first.
|
java.util.Iterator<Node> |
DocumentNavigator.getFollowingSiblingAxisIterator(java.lang.Object contextNode) |
Get an iterator over all following siblings.
|
java.util.Iterator<Node> |
DocumentNavigator.getParentAxisIterator(java.lang.Object contextNode) |
Get a (single-member) iterator over this node's parent.
|
java.util.Iterator<Node> |
DocumentNavigator.getPrecedingAxisIterator(java.lang.Object contextNode) |
Get an iterator over all preceding nodes, depth-first.
|
java.util.Iterator<Node> |
DocumentNavigator.getPrecedingSiblingAxisIterator(java.lang.Object contextNode) |
Get an iterator over all preceding siblings.
|
Modifier and Type | Method | Description |
---|---|---|
protected Node |
NodeIterator.getFirstChild(Node contextNode) |
|
protected abstract Node |
NodeIterator.getFirstNode(Node contextNode) |
|
protected Node |
NodeIterator.getLastChild(Node contextNode) |
|
protected abstract Node |
NodeIterator.getNextNode(Node contextNode) |
|
protected Node |
NodeIterator.getNextSibling(Node contextNode) |
|
protected Node |
NodeIterator.getPreviousSibling(Node contextNode) |
Constructor | Description |
---|---|
Attribute(Node parent,
java.lang.String name,
java.lang.reflect.Method m) |
|
Attribute(Node parent,
java.lang.String name,
java.lang.String value) |
|
AttributeAxisIterator(Node contextNode) |
|
NodeIterator(Node contextNode) |
Modifier and Type | Field | Description |
---|---|---|
protected Node |
ElementNode.node |
Modifier and Type | Field | Description |
---|---|---|
java.util.Map<Node,ElementNode> |
DocumentNode.nodeToElementNode |
Mapping from AST Node to corresponding ElementNode.
|
Constructor | Description |
---|---|
DocumentNode(Node node) |
Construct a DocumentNode, with the given AST Node serving as the root
ElementNode.
|
ElementNode(DocumentNode document,
IdGenerator idGenerator,
ElementNode parent,
Node node,
int siblingPosition) |
Modifier and Type | Interface | Description |
---|---|---|
interface |
DFAGraphMethod |
Modifier and Type | Field | Description |
---|---|---|
protected Node |
AbstractDataFlowNode.node |
Modifier and Type | Method | Description |
---|---|---|
Node |
AbstractDataFlowNode.getNode() |
|
Node |
DataFlowNode.getNode() |
Modifier and Type | Method | Description |
---|---|---|
DataFlowNode |
Structure.createNewNode(Node node) |
This class encapsulates the access to the DataFlowNode class.
|
Constructor | Description |
---|---|
AbstractDataFlowNode(java.util.List<DataFlowNode> dataFlow,
Node node) |
Modifier and Type | Class | Description |
---|---|---|
class |
AbstractMetric<N extends Node> |
Abstract class for all metrics.
|
class |
BasicMetricMemoizer<N extends Node> |
Basic implementation of a metric memoizer.
|
interface |
Metric<N extends Node> |
Object computing a metric on a node.
|
interface |
MetricKey<N extends Node> |
Key identifying a metric.
|
interface |
MetricMemoizer<N extends Node> |
Objects capable of memoizing metrics for a specific type of node.
|
class |
ParameterizedMetricKey<N extends Node> |
Represents a key parameterized with its options.
|
Modifier and Type | Method | Description |
---|---|---|
static <N extends Node> |
ParameterizedMetricKey.getInstance(MetricKey<N> key,
MetricOptions options) |
Builds a parameterized metric key.
|
static <T extends Node> |
MetricKeyUtil.of(java.lang.String name,
Metric<T> metric) |
Creates a new metric key holding a metric which can be computed on a class.
|
Modifier and Type | Class | Description |
---|---|---|
class |
ParametricRuleViolation<T extends Node> |
Modifier and Type | Field | Description |
---|---|---|
protected java.util.Map<java.lang.String,java.util.List<Node>> |
AbstractRuleChainVisitor.nodeNameToNodes |
This is a mapping from node names to nodes instances for the current AST.
|
Modifier and Type | Method | Description |
---|---|---|
Node |
ImportWrapper.getNode() |
Modifier and Type | Method | Description |
---|---|---|
void |
AbstractRule.addViolation(java.lang.Object data,
Node node) |
|
void |
AbstractRule.addViolation(java.lang.Object data,
Node node,
java.lang.Object[] args) |
|
void |
AbstractRule.addViolation(java.lang.Object data,
Node node,
java.lang.String arg) |
|
void |
AbstractRuleViolationFactory.addViolation(RuleContext ruleContext,
Rule rule,
Node node,
java.lang.String message,
int beginLine,
int endLine,
java.lang.Object[] args) |
|
void |
AbstractRuleViolationFactory.addViolation(RuleContext ruleContext,
Rule rule,
Node node,
java.lang.String message,
java.lang.Object[] args) |
|
void |
RuleViolationFactory.addViolation(RuleContext ruleContext,
Rule rule,
Node node,
java.lang.String message,
int beginLine,
int endLine,
java.lang.Object[] args) |
|
void |
RuleViolationFactory.addViolation(RuleContext ruleContext,
Rule rule,
Node node,
java.lang.String message,
java.lang.Object[] args) |
Adds a violation to the report.
|
void |
AbstractRule.addViolationWithMessage(java.lang.Object data,
Node node,
java.lang.String message) |
|
void |
AbstractRule.addViolationWithMessage(java.lang.Object data,
Node node,
java.lang.String message,
int beginLine,
int endLine) |
|
void |
AbstractRule.addViolationWithMessage(java.lang.Object data,
Node node,
java.lang.String message,
java.lang.Object[] args) |
|
protected abstract RuleViolation |
AbstractRuleViolationFactory.createRuleViolation(Rule rule,
RuleContext ruleContext,
Node node,
java.lang.String message) |
|
protected abstract RuleViolation |
AbstractRuleViolationFactory.createRuleViolation(Rule rule,
RuleContext ruleContext,
Node node,
java.lang.String message,
int beginLine,
int endLine) |
|
void |
XPathRule.evaluate(Node node,
RuleContext data) |
Evaluate the XPath query with the AST node.
|
protected void |
AbstractRuleChainVisitor.indexNode(Node node) |
Index a single node for visitation by rules.
|
protected abstract void |
AbstractRuleChainVisitor.visit(Rule rule,
Node node,
RuleContext ctx) |
Visit the given rule to the given node.
|
Modifier and Type | Method | Description |
---|---|---|
void |
AbstractDelegateRule.addRuleChainVisit(java.lang.Class<? extends Node> nodeClass) |
|
void |
AbstractRule.addRuleChainVisit(java.lang.Class<? extends Node> nodeClass) |
|
void |
AbstractDelegateRule.apply(java.util.List<? extends Node> nodes,
RuleContext ctx) |
|
void |
MockRule.apply(java.util.List<? extends Node> nodes,
RuleContext ctx) |
|
void |
XPathRule.apply(java.util.List<? extends Node> nodes,
RuleContext ctx) |
Apply the rule to all nodes.
|
protected abstract void |
AbstractRuleChainVisitor.indexNodes(java.util.List<Node> nodes,
RuleContext ctx) |
Index all nodes for visitation by rules.
|
void |
AbstractRuleChainVisitor.visitAll(java.util.List<Node> nodes,
RuleContext ctx) |
|
void |
RuleChainVisitor.visitAll(java.util.List<Node> nodes,
RuleContext ctx) |
Visit all the given Nodes provided using the given RuleContext.
|
Constructor | Description |
---|---|
ImportWrapper(java.lang.String fullname,
java.lang.String name,
Node node) |
|
ImportWrapper(java.lang.String fullname,
java.lang.String name,
Node node,
boolean isStaticDemand) |
|
ImportWrapper(java.lang.String fullname,
java.lang.String name,
Node node,
java.lang.Class<?> type,
boolean isStaticDemand) |
Modifier and Type | Method | Description |
---|---|---|
abstract java.util.List<Node> |
AbstractXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
JaxenXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
SaxonXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
XPathRuleQuery.evaluate(Node node,
RuleContext data) |
Evaluate the XPath query against the given Node.
|
Modifier and Type | Method | Description |
---|---|---|
abstract java.util.List<Node> |
AbstractXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
JaxenXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
SaxonXPathRuleQuery.evaluate(Node node,
RuleContext data) |
|
java.util.List<Node> |
XPathRuleQuery.evaluate(Node node,
RuleContext data) |
Evaluate the XPath query against the given Node.
|
Modifier and Type | Interface | Description |
---|---|---|
interface |
ScopedNode |
A
Node which knows about the scope within it has been declared. |
Modifier and Type | Method | Description |
---|---|---|
Node |
DataPoint.getNode() |
Modifier and Type | Method | Description |
---|---|---|
void |
DataPoint.setNode(Node node) |
Modifier and Type | Method | Description |
---|---|---|
void |
CodeEditorTextPane.select(Node node) |
Deprecated.
|
void |
DFAPanel.DFACanvas.setMethod(Node node) |
Constructor | Description |
---|---|
ASTNodePopupMenu(ViewerModel model,
Node node) |
Deprecated.
|
AttributesSubMenu(ViewerModel model,
Node node) |
Deprecated.
|
SimpleNodeSubMenu(ViewerModel model,
Node node) |
Deprecated.
constructs the submenu
|
Modifier and Type | Method | Description |
---|---|---|
Node |
ViewerModel.getRootNode() |
Deprecated.
|
Node |
SimpleNodeTreeNodeAdapter.getSimpleNode() |
Deprecated.
retrieves the underlying node
|
Modifier and Type | Method | Description |
---|---|---|
java.util.List<Node> |
ViewerModel.getLastEvaluationResults() |
Deprecated.
Retrieves the results of last evaluation.
|
Modifier and Type | Method | Description |
---|---|---|
void |
ViewerModel.selectNode(Node node,
java.lang.Object selector) |
Deprecated.
Selects the given node in the AST.
|
Constructor | Description |
---|---|
ASTModel(Node root) |
Deprecated.
creates the tree model
|
SimpleNodeTreeNodeAdapter(SimpleNodeTreeNodeAdapter parent,
Node node) |
Deprecated.
constructs the node
|
Copyright © 2002–2018 PMD. All rights reserved.