Top Description Methods
java.lang.classfile

public sealed Interface Superclass

extends ClassElement
Known Direct Implementers
jdk.internal.classfile.impl.SuperclassImpl
Annotations
@PreviewFeature
feature:CLASSFILE_API
Imports
java.lang.classfile.constantpool.ClassEntry, jdk.internal.classfile.impl.SuperclassImpl, jdk.internal.javac.PreviewFeature

Preview

Second Preview of ClassFile API (JEP 466).

Programs can only use Superclass when preview features are enabled.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.

Models the superclass of a class. Delivered as a java.lang.classfile.ClassElement when traversing a ClassModel.
Since
22

Method Summary

Modifier and TypeMethod and Description
public static Superclass

Returns:

a Superclass element
of
(ClassEntry
the superclass
superclassEntry
)

Returns a Superclass element.

public ClassEntry

Returns:

the superclass
superclassEntry
()

Returns the superclass.

Method Detail

ofback to summary
public static Superclass of(ClassEntry superclassEntry)

Returns a Superclass element.

Parameters
superclassEntry:ClassEntry

the superclass

Returns:Superclass

a Superclass element

superclassEntryback to summary
public ClassEntry superclassEntry()

Returns the superclass.

Returns:ClassEntry

the superclass