Class AbstractTypeAwareJavaElement

All Implemented Interfaces:
AnnotatedElement, AnnotationMetadata, AnnotationMetadataDelegate, AnnotationMetadataProvider, AnnotationSource, Described, Named, MutableAnnotationMetadataDelegate<Element>, Element
Direct Known Subclasses:
AbstractJavaMemberElement, JavaClassElement

@Internal public abstract class AbstractTypeAwareJavaElement extends AbstractJavaElement
An abstract class that is aware of the use-type.
Since:
4.10
Author:
Denis Stepanov
  • Method Details

    • hasNullMarked

      protected abstract boolean hasNullMarked()
      Checks if the element is explicitly marked as null-marked.
      Returns:
      true if the element is marked as null-marked, false otherwise
    • getTypeAnnotationMetadata

      protected abstract AnnotationMetadata getTypeAnnotationMetadata()
      Retrieves the metadata of annotations associated with the type of the current element.
      Returns:
      the AnnotationMetadata representing the annotations of the type.
    • isDeclaredNullable

      public final boolean isDeclaredNullable()
      Returns:
      Whether the element is nullable.
    • isNullable

      public final boolean isNullable()
      Returns:
      Whether the element is nullable.
    • isNonNull

      public final boolean isNonNull()
      Returns:
      Whether the element is declared as not being null
    • isDeclaredNonNull

      public final boolean isDeclaredNonNull()
      Returns:
      Whether the element is declared as not being null
    • canBeMarkedWithNonNull

      protected final boolean canBeMarkedWithNonNull(ClassElement classElement)