public static class FlowExpressionParseUtil.FlowExpressionContext extends Object
@A(E)
,
The context is the program element that is annotated by @A(E)
.Modifier and Type | Field and Description |
---|---|
List<FlowExpressions.Receiver> |
arguments |
BaseContext |
checkerContext |
FlowExpressions.Receiver |
outerReceiver |
boolean |
parsingMember |
FlowExpressions.Receiver |
receiver |
boolean |
useLocalScope |
Constructor and Description |
---|
FlowExpressionContext(FlowExpressions.Receiver receiver,
List<FlowExpressions.Receiver> arguments,
BaseContext checkerContext)
Creates context for parsing a flow expression.
|
public final FlowExpressions.Receiver receiver
public final List<FlowExpressions.Receiver> arguments
public final FlowExpressions.Receiver outerReceiver
public final BaseContext checkerContext
public final boolean parsingMember
public boolean useLocalScope
public FlowExpressionContext(FlowExpressions.Receiver receiver, List<FlowExpressions.Receiver> arguments, BaseContext checkerContext)
receiver
- used to replace "this" in a flow expression and used to resolve
identifiers in the flow expression with an implicit "this"arguments
- used to replace parameter references, e.g. #1, in flow expressionscheckerContext
- used to create FlowExpressions.Receiver
spublic static FlowExpressionParseUtil.FlowExpressionContext buildContextForMethodDeclaration(MethodTree methodDeclaration, Tree enclosingTree, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the method declared in methodDeclaration
.methodDeclaration
- Used translate parameter numbers in a flow expression to formal parameters of
the method.enclosingTree
- Used to look up fields and as type of "this" in flow expressionscheckerContext
- use to build FlowExpressions.ReceivermethodDeclaration
public static FlowExpressionParseUtil.FlowExpressionContext buildContextForMethodDeclaration(MethodTree methodDeclaration, TypeMirror enclosingType, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the method declared in methodDeclaration
.methodDeclaration
- Used translate parameter numbers in a flow expression to formal parameters of
the method.enclosingType
- Used to look up fields and as type of "this" in flow expressionscheckerContext
- use to build FlowExpressions.ReceivermethodDeclaration
public static FlowExpressionParseUtil.FlowExpressionContext buildContextForMethodDeclaration(MethodTree methodDeclaration, TreePath currentPath, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the method declared in methodDeclaration
.methodDeclaration
- Used translate parameter numbers in a flow expression to formal
parameters of the method.currentPath
- To find the enclosing class, which is used to look up fields and as type
of "this" in flow expressionscheckerContext
- use to build FlowExpressions.ReceivermethodDeclaration
public static FlowExpressionParseUtil.FlowExpressionContext buildContextForClassDeclaration(ClassTree classTree, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the class classTree
as
seen at the class declaration.public static FlowExpressionParseUtil.FlowExpressionContext buildContextForMethodUse(MethodInvocationNode methodInvocation, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the method methodInvocation
(represented as a Node
as seen at the method use (i.e.,
at a method call site).public static FlowExpressionParseUtil.FlowExpressionContext buildContextForNewClassUse(ObjectCreationNode n, BaseContext checkerContext)
FlowExpressionParseUtil.FlowExpressionContext
for the constructor n
(represented as a Node
as seen at the method use (i.e.,
at a method call site).public FlowExpressionParseUtil.FlowExpressionContext copyChangeToParsingMemberOfReceiver(FlowExpressions.Receiver receiver)
public FlowExpressionParseUtil.FlowExpressionContext copyAndUseOuterReceiver()