Class RecordComponentDescription.Latent

All Implemented Interfaces:
AnnotationSource, ByteCodeElement.TypeDependant<RecordComponentDescription.InDefinedShape,RecordComponentDescription.Token>, DeclaredByType, DeclaredByType.WithMandatoryDeclaration, NamedElement, NamedElement.WithDescriptor, RecordComponentDescription, RecordComponentDescription.InDefinedShape
Enclosing interface:
RecordComponentDescription

public static class RecordComponentDescription.Latent extends RecordComponentDescription.InDefinedShape.AbstractBase
A latent record component description.
  • Field Details

    • declaringType

      private final TypeDescription declaringType
      The record component's declaring type.
    • name

      private final String name
      The record component's name.
    • type

      private final TypeDescription.Generic type
      The record component's type.
    • annotations

      private final List<? extends AnnotationDescription> annotations
      The record component's annotations.
  • Constructor Details

    • Latent

      public Latent(TypeDescription declaringType, RecordComponentDescription.Token token)
      Creates a new latent record component.
      Parameters:
      declaringType - The record component's declaring type.
      token - The token representing the record component's detached properties.
    • Latent

      public Latent(TypeDescription declaringType, String name, TypeDescription.Generic type, List<? extends AnnotationDescription> annotations)
      Creates a new latent record component.
      Parameters:
      declaringType - The record component's declaring type-
      name - The record component's name.
      type - The record component's type.
      annotations - The record component's annotations.
  • Method Details

    • getType

      public TypeDescription.Generic getType()
      Returns the type of the record.
      Returns:
      The type of the record.
    • getDeclaringType

      @Nonnull public TypeDescription getDeclaringType()
      Returns the declaring type of this instance.
      Returns:
      The declaring type or null if no such type exists.
    • getActualName

      public String getActualName()
      Returns the display name of this element as it is found in the source code. If no such name exists, an empty string is returned.
      Returns:
      The name of this element as given in a Java program's source code.
    • getDeclaredAnnotations

      public AnnotationList getDeclaredAnnotations()
      Returns a list of annotations that are declared by this instance.
      Returns:
      A list of declared annotations.