Class DefaultQualifierKindHierarchy.DefaultQualifierKind
java.lang.Object
org.checkerframework.framework.util.DefaultQualifierKindHierarchy.DefaultQualifierKind
- All Implemented Interfaces:
Comparable<QualifierKind>
,QualifierKind
- Enclosing class:
DefaultQualifierKindHierarchy
@AnnotatedFor("nullness")
@Interned
public static class DefaultQualifierKindHierarchy.DefaultQualifierKind
extends Object
implements QualifierKind
The default implementation of
QualifierKind
.
The fields in this class that refer to QualifierKind
s are set when creating the
DefaultQualifierKindHierarchy
. So the getter methods for these fields should not be
called until after the DefaultQualifierKindHierarchy
is created.
-
Field Summary
Modifier and TypeFieldDescriptionThe bottom of the hierarchy to which this belongs.The polymorphic qualifier of the hierarchy to which this belongs.protected @MonotonicNonNull Set
<QualifierKind> All the qualifier kinds that are a strict super qualifier kind of this.The top of the hierarchy to which this belongs. -
Method Summary
Modifier and TypeMethodDescriptionClass
<? extends Annotation> Returns the annotation class for this.Returns the bottom qualifier kind of the hierarchy to which this qualifier kind belongs.getName()
Returns the canonical name of the annotation class of this.Returns the polymorphic qualifier kind of the hierarchy to which this qualifier kind belongs, or null if one does not exist.Set
<? extends QualifierKind> All the qualifier kinds that are a strict super qualifier of this qualifier.getTop()
Returns the top qualifier kind of the hierarchy to which this qualifier kind belongs.boolean
Returns true if the annotation class this qualifier kind represents has annotation elements/arguments.boolean
isBottom()
Returns true if this is the bottom qualifier of its hierarchy.boolean
isInSameHierarchyAs
(QualifierKind other) Returns true if this andother
are in the same hierarchy.boolean
isPoly()
Returns true if this is polymorphic.boolean
isSubtypeOf
(QualifierKind superQualKind) Returns true if this qualifier kind is a subtype of or equal tosuperQualKind
.boolean
isTop()
Returns true if this is the top qualifier of its hierarchy.toString()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.checkerframework.framework.util.QualifierKind
compareTo
-
Field Details
-
top
The top of the hierarchy to which this belongs. -
bottom
The bottom of the hierarchy to which this belongs. -
poly
The polymorphic qualifier of the hierarchy to which this belongs. -
strictSuperTypes
All the qualifier kinds that are a strict super qualifier kind of this. Does not include this qualifier kind itself.
-
-
Method Details
-
getName
Description copied from interface:QualifierKind
Returns the canonical name of the annotation class of this.- Specified by:
getName
in interfaceQualifierKind
- Returns:
- the canonical name of the annotation class of this
-
getAnnotationClass
Description copied from interface:QualifierKind
Returns the annotation class for this.- Specified by:
getAnnotationClass
in interfaceQualifierKind
- Returns:
- the annotation class for this
-
getTop
Description copied from interface:QualifierKind
Returns the top qualifier kind of the hierarchy to which this qualifier kind belongs.- Specified by:
getTop
in interfaceQualifierKind
- Returns:
- the top qualifier kind of the hierarchy to which this qualifier kind belongs
-
isTop
public boolean isTop()Description copied from interface:QualifierKind
Returns true if this is the top qualifier of its hierarchy.- Specified by:
isTop
in interfaceQualifierKind
- Returns:
- true if this is the top qualifier of its hierarchy
-
getBottom
Description copied from interface:QualifierKind
Returns the bottom qualifier kind of the hierarchy to which this qualifier kind belongs.- Specified by:
getBottom
in interfaceQualifierKind
- Returns:
- the bottom qualifier kind of the hierarchy to which this qualifier kind belongs
-
isBottom
public boolean isBottom()Description copied from interface:QualifierKind
Returns true if this is the bottom qualifier of its hierarchy.- Specified by:
isBottom
in interfaceQualifierKind
- Returns:
- true if this is the bottom qualifier of its hierarchy
-
getPolymorphic
Description copied from interface:QualifierKind
Returns the polymorphic qualifier kind of the hierarchy to which this qualifier kind belongs, or null if one does not exist.- Specified by:
getPolymorphic
in interfaceQualifierKind
- Returns:
- the polymorphic qualifier kind of the hierarchy to which this qualifier kind belongs, or null if one does not exist
-
isPoly
Description copied from interface:QualifierKind
Returns true if this is polymorphic.- Specified by:
isPoly
in interfaceQualifierKind
- Returns:
- true if this is polymorphic
-
hasElements
public boolean hasElements()Description copied from interface:QualifierKind
Returns true if the annotation class this qualifier kind represents has annotation elements/arguments.- Specified by:
hasElements
in interfaceQualifierKind
- Returns:
- true if the annotation class this qualifier kind represents has elements/arguments
-
getStrictSuperTypes
Description copied from interface:QualifierKind
All the qualifier kinds that are a strict super qualifier of this qualifier. Does not include this qualifier kind itself.- Specified by:
getStrictSuperTypes
in interfaceQualifierKind
- Returns:
- all the qualifier kinds that are a strict super qualifier of this qualifier
-
isInSameHierarchyAs
Description copied from interface:QualifierKind
Returns true if this andother
are in the same hierarchy.- Specified by:
isInSameHierarchyAs
in interfaceQualifierKind
- Parameters:
other
- a qualifier kind- Returns:
- true if this and
other
are in the same hierarchy
-
isSubtypeOf
Description copied from interface:QualifierKind
Returns true if this qualifier kind is a subtype of or equal tosuperQualKind
.- Specified by:
isSubtypeOf
in interfaceQualifierKind
- Parameters:
superQualKind
- other qualifier kind- Returns:
- true if this qualifier kind is a subtype of or equal to
superQualKind
-
toString
-