Interface Utf8Entry
- All Superinterfaces:
AnnotationConstantValueEntryPREVIEW,CharSequence,ClassFileElementPREVIEW,PoolEntryPREVIEW,WritableElementPREVIEW<PoolEntryPREVIEW>
Utf8Entry is a preview API of the Java platform.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.
Models a
CONSTANT_UTF8_info constant in the constant pool of a
classfile.- See Java Virtual Machine Specification:
-
4.4.7 The CONSTANT_Utf8_info Structure
- Since:
- 22
-
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whether this entry describes the same string as the provided string.Returns the string value for this entry.Methods declared in interface java.lang.classfile.constantpool.AnnotationConstantValueEntryPREVIEW
constantValueMethods declared in interface java.lang.CharSequence
charAt, chars, codePoints, isEmpty, length, subSequence, toStringMethods declared in interface java.lang.classfile.constantpool.PoolEntryPREVIEW
constantPool, index, tag, widthMethods declared in interface java.lang.classfile.WritableElementPREVIEW
writeTo
-
Method Details
-
stringValue
String stringValue()Returns the string value for this entry.- Returns:
- the string value for this entry
-
equalsString
Returns whether this entry describes the same string as the provided string.- Parameters:
s- the string to compare to- Returns:
- whether this entry describes the same string as the provided string
-
Utf8Entrywhen preview features are enabled.