public class OffsetDependentTypesHelper extends DependentTypesHelper
array.length - 1
.factory, objectTM
Constructor and Description |
---|
OffsetDependentTypesHelper(AnnotatedTypeFactory factory) |
Modifier and Type | Method and Description |
---|---|
TreeAnnotator |
createDependentTypesTreeAnnotator()
Creates a TreeAnnotator that viewpoint-adapts dependent type annotations.
|
protected @Nullable JavaExpression |
transform(JavaExpression javaExpr)
This method is for subclasses to override to change JavaExpressions in some way before they are
inserted into new annotations.
|
atConstructorInvocation, atExpression, atFieldAccess, atLocalVariable, atMethodBody, atMethodInvocation, atParameterizedTypeUse, atTypeDecl, atVariableDeclaration, buildAnnotation, checkAnnotationForErrorExpressions, checkClassForErrorExpressions, checkMethodForErrorExpressions, checkTypeForErrorExpressions, convertAnnotatedTypeMirror, convertAnnotationMirror, createError, createError, delocalize, hasDependentAnnotations, reportErrors, shouldPassThroughExpression
public OffsetDependentTypesHelper(AnnotatedTypeFactory factory)
protected @Nullable JavaExpression transform(JavaExpression javaExpr)
DependentTypesHelper
javaExpr
may be a PassThroughExpression
.
If null
is returned then the expression is not added to the new annotation.
The default implementation returns the argument, but subclasses may override it.
transform
in class DependentTypesHelper
javaExpr
- a JavaExpressionnull
if no transformation existspublic TreeAnnotator createDependentTypesTreeAnnotator()
DependentTypesHelper
createDependentTypesTreeAnnotator
in class DependentTypesHelper