public class FlowExpressions extends Object
Modifier and Type | Class and Description |
---|---|
static class |
FlowExpressions.ArrayAccess
A deterministic method call.
|
static class |
FlowExpressions.ArrayCreation |
static class |
FlowExpressions.ClassName
A ClassName represents the occurrence of a class as part of a static field access or method
invocation.
|
static class |
FlowExpressions.FieldAccess |
static class |
FlowExpressions.LocalVariable |
static class |
FlowExpressions.MethodCall
A method call.
|
static class |
FlowExpressions.Receiver |
static class |
FlowExpressions.ThisReference |
static class |
FlowExpressions.Unknown |
static class |
FlowExpressions.ValueLiteral |
Constructor and Description |
---|
FlowExpressions() |
Modifier and Type | Method and Description |
---|---|
static List<FlowExpressions.Receiver> |
getParametersOfEnclosingMethod(AnnotationProvider annotationProvider,
TreePath path)
Returns Receiver objects for the formal parameters of the method in which path is enclosed.
|
static FlowExpressions.Receiver |
internalRepOfImplicitReceiver(Element ele)
Returns the implicit receiver of ele.
|
static FlowExpressions.Receiver |
internalRepOfPseudoReceiver(TreePath path,
TypeMirror enclosingType)
Returns either a new ClassName or ThisReference Receiver object for the enclosingType
|
static FlowExpressions.Receiver |
internalReprOf(AnnotationProvider provider,
ExpressionTree receiverTree) |
static FlowExpressions.Receiver |
internalReprOf(AnnotationProvider provider,
ExpressionTree receiverTree,
boolean allowNonDeterministic)
We ignore operations such as widening and narrowing when computing the internal
representation.
|
static FlowExpressions.Receiver |
internalReprOf(AnnotationProvider provider,
Node receiverNode)
We ignore operations such as widening and narrowing when computing the internal
representation.
|
static FlowExpressions.Receiver |
internalReprOf(AnnotationProvider provider,
Node receiverNode,
boolean allowNonDeterministic)
We ignore operations such as widening and narrowing when computing the internal
representation.
|
static FlowExpressions.ArrayAccess |
internalReprOfArrayAccess(AnnotationProvider provider,
ArrayAccessNode node) |
static FlowExpressions.FieldAccess |
internalReprOfFieldAccess(AnnotationProvider provider,
FieldAccessNode node) |
public static FlowExpressions.FieldAccess internalReprOfFieldAccess(AnnotationProvider provider, FieldAccessNode node)
FlowExpressions.FieldAccess
) of a FieldAccessNode
.
Can contain FlowExpressions.Unknown
as receiver.public static FlowExpressions.ArrayAccess internalReprOfArrayAccess(AnnotationProvider provider, ArrayAccessNode node)
FlowExpressions.FieldAccess
) of a FieldAccessNode
.
Can contain FlowExpressions.Unknown
as receiver.public static FlowExpressions.Receiver internalReprOf(AnnotationProvider provider, Node receiverNode)
FlowExpressions.Receiver
) of any Node
. Might contain
FlowExpressions.Unknown
.public static FlowExpressions.Receiver internalReprOf(AnnotationProvider provider, Node receiverNode, boolean allowNonDeterministic)
FlowExpressions.Receiver
) of any Node
. Might contain
FlowExpressions.Unknown
.public static FlowExpressions.Receiver internalReprOf(AnnotationProvider provider, ExpressionTree receiverTree)
FlowExpressions.Receiver
) of any ExpressionTree
.
Might contain FlowExpressions.Unknown
.public static FlowExpressions.Receiver internalReprOf(AnnotationProvider provider, ExpressionTree receiverTree, boolean allowNonDeterministic)
FlowExpressions.Receiver
) of any ExpressionTree
.
Might contain FlowExpressions.Unknown
.public static FlowExpressions.Receiver internalRepOfImplicitReceiver(Element ele)
Returns either a new ClassName or a new ThisReference depending on whether ele is static or not. The passed element must be a field, method, or class.
ele
- field, method, or classpublic static FlowExpressions.Receiver internalRepOfPseudoReceiver(TreePath path, TypeMirror enclosingType)
The Tree should be an expression or a statement that does not have a receiver or an implicit receiver. For example, a local variable declaration.
path
- TreePath to treeenclosingType
- type of the enclosing typepublic static List<FlowExpressions.Receiver> getParametersOfEnclosingMethod(AnnotationProvider annotationProvider, TreePath path)
annotationProvider
- annotationProviderpath
- TreePath that is enclosed by the method