checkers.lock
Class LockAnnotatedTypeFactory
java.lang.Object
checkers.types.AnnotatedTypeFactory
checkers.types.BasicAnnotatedTypeFactory<LockChecker>
checkers.lock.LockAnnotatedTypeFactory
public class LockAnnotatedTypeFactory
extends BasicAnnotatedTypeFactory<LockChecker>
The type factory for Lock
type system.
The annotated types returned by class contain GuardedBy
type
qualifiers only for the locks that are not currently held.
Fields inherited from class checkers.types.AnnotatedTypeFactory |
annotations, atypes, elements, env, fromTreeCache, qualHierarchy, root, trees, types, uid, visitorState |
Methods inherited from class checkers.types.AnnotatedTypeFactory |
annotateInheritedFromClass, canHaveAnnotatedTypeParameters, constructorFromUse, createLRUCache, declarationFromElement, fromClass, fromElement, fromElement, fromElement, fromExpression, fromMember, fromNewClass, fromTypeTree, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedType, getAnnotatedTypeFromTypeTree, getBoxedType, getCurrentClassType, getCurrentMethodReceiver, getEnclosingType, getImplicitReceiverType, getPath, getQualifierHierarchy, getReceiver, getSelfType, getUnboxedType, getVisitorState, isMostEnclosingThisDeref, isWithinConstructor, postAsMemberOf, toString, unify |
LockAnnotatedTypeFactory
public LockAnnotatedTypeFactory(LockChecker checker,
CompilationUnitTree root)
setHeldLocks
public void setHeldLocks(List<String> heldLocks)
getHeldLock
public List<String> getHeldLock()
annotateImplicit
protected void annotateImplicit(Tree tree,
AnnotatedTypeMirror type)
- Description copied from class:
AnnotatedTypeFactory
- Adds implicit annotations to a type obtained from a
Tree
. By
default, this method does nothing. Subclasses should use this method to
implement implicit annotations specific to their type systems.
- Overrides:
annotateImplicit
in class BasicAnnotatedTypeFactory<LockChecker>
- Parameters:
tree
- an AST nodetype
- the type obtained from tree
aliasedAnnotation
protected AnnotationMirror aliasedAnnotation(AnnotationMirror a)
- Description copied from class:
AnnotatedTypeFactory
- Returns the canonical annotation for the passed annotation if it is
an alias of a canonical one in the framework. If it is not an alias,
the method returns null.
Returns an aliased type of the current one
- Overrides:
aliasedAnnotation
in class AnnotatedTypeFactory