Interface TypeDescription.ForLoadedType.Dispatcher

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.reflect.AnnotatedElement[] getAnnotatedInterfaces​(java.lang.Class<?> type)
      Resolves the annotated interfaces of the supplied type.
      java.lang.reflect.AnnotatedElement getAnnotatedSuperclass​(java.lang.Class<?> type)
      Resolves the annotated super class of the supplied type.
      java.lang.Class<?> getNestHost​(java.lang.Class<?> type)
      Returns the specified class's nest host.
      java.lang.Class<?>[] getNestMembers​(java.lang.Class<?> type)
      Returns the nest members of the other class.
      java.lang.Class<?>[] getPermittedSubclasses​(java.lang.Class<?> type)
      Returns the permitted subclasses of the supplied type.
      java.lang.Object[] getRecordComponents​(java.lang.Class<?> type)
      Resolves a type's record components.
      boolean isNestmateOf​(java.lang.Class<?> type, java.lang.Class<?> candidate)
      Returns true if the specified type is a nest mate of the other type.
      boolean isRecord​(java.lang.Class<?> type)
      Checks if the supplied type is a record.
      boolean isSealed​(java.lang.Class<?> type)
      Checks if this type is sealed.
    • Method Detail

      • getAnnotatedSuperclass

        java.lang.reflect.AnnotatedElement getAnnotatedSuperclass​(java.lang.Class<?> type)
        Resolves the annotated super class of the supplied type.
        Parameters:
        type - The type to resolve.
        Returns:
        The annotated super class of the supplied type or null if this feature is not supported.
      • getAnnotatedInterfaces

        java.lang.reflect.AnnotatedElement[] getAnnotatedInterfaces​(java.lang.Class<?> type)
        Resolves the annotated interfaces of the supplied type.
        Parameters:
        type - The type to resolve.
        Returns:
        An array of the type's annotated interfaces or an empty array if this feature is not supported.
      • getNestHost

        java.lang.Class<?> getNestHost​(java.lang.Class<?> type)
        Returns the specified class's nest host.
        Parameters:
        type - The class for which to locate the nest host.
        Returns:
        The nest host of the specified class.
      • getNestMembers

        java.lang.Class<?>[] getNestMembers​(java.lang.Class<?> type)
        Returns the nest members of the other class.
        Parameters:
        type - The type to get the nest members for.
        Returns:
        An array containing all nest members of the specified type's nest group.
      • isNestmateOf

        boolean isNestmateOf​(java.lang.Class<?> type,
                             java.lang.Class<?> candidate)
        Returns true if the specified type is a nest mate of the other type.
        Parameters:
        type - The type to evaluate for being a nest mate of another type.
        candidate - The candidate type.
        Returns:
        true if the specified type is a nest mate of the other class.
      • isSealed

        boolean isSealed​(java.lang.Class<?> type)
        Checks if this type is sealed. This will always be false if the current VM does not support sealed classes.
        Parameters:
        type - The type to check
        Returns:
        true if the supplied type is sealed.
      • getPermittedSubclasses

        java.lang.Class<?>[] getPermittedSubclasses​(java.lang.Class<?> type)
        Returns the permitted subclasses of the supplied type.
        Parameters:
        type - The type for which to check the permitted subclasses.
        Returns:
        The permitted subclasses.
      • isRecord

        boolean isRecord​(java.lang.Class<?> type)
        Checks if the supplied type is a record.
        Parameters:
        type - The type to resolve.
        Returns:
        true if the supplied type is a record.
      • getRecordComponents

        java.lang.Object[] getRecordComponents​(java.lang.Class<?> type)
        Resolves a type's record components.
        Parameters:
        type - The type for which to read the record components.
        Returns:
        An array of all declared record components.