public final class TemplateAstMatcher
extends java.lang.Object
Constructor and Description |
---|
TemplateAstMatcher(TypeIRegistry typeRegistry,
Node templateFunctionNode,
TypeMatchingStrategy typeMatchingStrategy)
Constructs this matcher with a Function node that serves as the template
to match all other nodes against.
|
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,Node> |
getTemplateNodeToMatchMap()
Returns a map from named template Nodes (such as parameters
or local variables) to Nodes that were matches from the last matched
template.
|
boolean |
isLooseMatch() |
boolean |
matches(Node n) |
public TemplateAstMatcher(TypeIRegistry typeRegistry, Node templateFunctionNode, TypeMatchingStrategy typeMatchingStrategy)
public boolean matches(Node n)
n
- The node to check.public boolean isLooseMatch()
public java.util.Map<java.lang.String,Node> getTemplateNodeToMatchMap()
Copyright © 2009-2017 Google. All Rights Reserved.