Top Description Methods
java.lang.classfile.constantpool

public sealed Interface MemberRefEntry

extends PoolEntry
Known Direct Subinterfaces
java.lang.classfile.constantpool.MethodRefEntry, java.lang.classfile.constantpool.FieldRefEntry, java.lang.classfile.constantpool.InterfaceMethodRefEntry
Known Direct Implementers
jdk.internal.classfile.impl.AbstractPoolEntry.AbstractMemberRefEntry
Annotations
@PreviewFeature
feature:CLASSFILE_API
Imports
jdk.internal.classfile.impl.AbstractPoolEntry, jdk.internal.javac.PreviewFeature

Preview

Second Preview of ClassFile API (JEP 466).

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

Models a member reference constant in the constant pool of a classfile, which includes references to fields, methods, and interface methods.
Since
22

Method Summary

Modifier and TypeMethod and Description
public default Utf8Entry

Returns:

the name of the member
name
()

Returns the name of the member.

public NameAndTypeEntry

Returns:

the name and type of the member
nameAndType
()

Returns the name and type of the member.

public ClassEntry

Returns:

the class in which this member ref lives
owner
()

Returns the class in which this member ref lives.

public default Utf8Entry

Returns:

the type of the member
type
()

Returns the type of the member.

Inherited from java.lang.classfile.constantpool.PoolEntry:
constantPoolindextagwidth

Method Detail

nameback to summary
public default Utf8Entry name()

Returns the name of the member.

Returns:Utf8Entry

the name of the member

nameAndTypeback to summary
public NameAndTypeEntry nameAndType()

Returns the name and type of the member.

Returns:NameAndTypeEntry

the name and type of the member

ownerback to summary
public ClassEntry owner()

Returns the class in which this member ref lives.

Returns:ClassEntry

the class in which this member ref lives

typeback to summary
public default Utf8Entry type()

Returns the type of the member.

Returns:Utf8Entry

the type of the member