Top ClassFile API Implicit Classes Language Model Module Imports Scoped Values Stream Gatherers Structured Concurrency
OpenJDK 1.23

Preview API


ClassFile API (Second Preview of JEP 466) Summary

SincePreview Item and Description
22
java.lang.classfile

Provides classfile parsing, generation, and transformation library.

22
java.lang.classfile.AccessFlags

Models the access flags for a class, method, or field.

22
java.lang.classfile.Annotation

Models an annotation on a declaration.

22
java.lang.classfile.AnnotationElement

Models a key-value pair of an annotation.

22
java.lang.classfile.AnnotationValue

Models the value of a key-value pair of an annotation.

22
java.lang.classfile.AnnotationValue.OfAnnotation

Models an annotation-valued element

22
java.lang.classfile.AnnotationValue.OfArray

Models an array-valued element

22
java.lang.classfile.AnnotationValue.OfBoolean

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfByte

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfCharacter

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfClass

Models a class-valued element

22
java.lang.classfile.AnnotationValue.OfConstant

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfDouble

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfEnum

Models an enum-valued element

22
java.lang.classfile.AnnotationValue.OfFloat

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfInteger

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfLong

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfShort

Models a constant-valued element

22
java.lang.classfile.AnnotationValue.OfString

Models a constant-valued element

22
java.lang.classfile.Attribute<
the attribute type
A extends Attribute<A>
>

Models a classfile attribute 4.7.

22
java.lang.classfile.AttributeMapper<
the attribute type
A
>

Bidirectional mapper between the classfile representation of an attribute and how that attribute is modeled in the API.

22
22
java.lang.classfile.AttributedElement

A ClassFileElement describing an entity that has attributes, such as a class, field, method, code attribute, or record component.

22
java.lang.classfile.Attributes

Attribute mappers for standard classfile attributes.

22
java.lang.classfile.BootstrapMethodEntry

Models an entry in the bootstrap method table.

22
java.lang.classfile.BufWriter

Supports writing portions of a classfile to a growable buffer.

22
java.lang.classfile.ClassBuilder

A builder for classfiles.

22
java.lang.classfile.ClassElement

A marker interface for elements that can appear when traversing a ClassModel or be presented to a ClassBuilder.

22
java.lang.classfile.ClassFile

Represents a context for parsing, transforming, and generating classfiles.

22
java.lang.classfile.ClassFile.AttributeMapperOption

Option describing attribute mappers for custom attributes.

22
java.lang.classfile.ClassFile.AttributesProcessingOption

Option describing whether to process or discard unrecognized or problematic original attributes when a class, record component, field, method or code is transformed in its exploded form.

22
java.lang.classfile.ClassFile.ClassHierarchyResolverOption

Option describing the class hierarchy resolver to use when generating stack maps.

22
java.lang.classfile.ClassFile.ConstantPoolSharingOption

Option describing whether to preserve the original constant pool when transforming a classfile.

22
java.lang.classfile.ClassFile.DeadCodeOption

Option describing whether to patch out unreachable code.

22
java.lang.classfile.ClassFile.DeadLabelsOption

Option describing whether to filter unresolved labels.

22
java.lang.classfile.ClassFile.DebugElementsOption

Option describing whether to process or discard debug elements.

22
java.lang.classfile.ClassFile.LineNumbersOption

Option describing whether to process or discard line numbers.

22
java.lang.classfile.ClassFile.Option

An option that affects the parsing and writing of classfiles.

22
java.lang.classfile.ClassFile.ShortJumpsOption

Option describing whether to automatically rewrite short jumps to long when necessary.

22
java.lang.classfile.ClassFile.StackMapsOption

Option describing whether to generate stackmaps.

22
java.lang.classfile.ClassFileBuilder<
the element type
E extends ClassFileElement
,
the builder type
B extends ClassFileBuilder<E, B>
>

A builder for a classfile or portion of a classfile.

22
java.lang.classfile.ClassFileElement

Immutable model for a portion of (or the entirety of) a classfile.

22
java.lang.classfile.ClassFileTransform<
the transform type
C extends ClassFileTransform<C, E, B>
,
the element type
E extends ClassFileElement
,
the builder type
B extends ClassFileBuilder<E, B>
>

A transformation on streams of elements.

22
java.lang.classfile.ClassFileTransform.ResolvedTransform<
the element type
E extends ClassFileElement
>

The result of binding a transform to a builder.

22
java.lang.classfile.ClassFileVersion

Models the classfile version information for a class.

22
java.lang.classfile.ClassHierarchyResolver

Provides class hierarchy information for generating correct stack maps during code building.

22
22
java.lang.classfile.ClassModel

Models a classfile.

22
java.lang.classfile.ClassReader

Supports reading from a classfile.

22
java.lang.classfile.ClassSignature

Models the generic signature of a class file, as defined by 4.7.9.

22
java.lang.classfile.ClassTransform

A transformation on streams of ClassElement.

22
java.lang.classfile.CodeBuilder

A builder for code attributes (method bodies).

22
22
java.lang.classfile.CodeBuilder.CatchBuilder

A builder to add catch blocks.

22
java.lang.classfile.CodeElement

A marker interface for elements that can appear when traversing a CodeModel or be presented to a CodeBuilder.

22
java.lang.classfile.CodeModel

Models the body of a method (the Code attribute).

22
java.lang.classfile.CodeTransform

A transformation on streams of CodeElement.

22
java.lang.classfile.CompoundElement<
the element type
E extends ClassFileElement
>

A ClassFileElement that has complex structure defined in terms of other classfile elements, such as a method, field, method body, or entire class.

22
java.lang.classfile.CustomAttribute<
the custom attribute type
T extends CustomAttribute<T>
>

Models a non-standard attribute of a classfile.

22
java.lang.classfile.FieldBuilder

A builder for fields.

22
java.lang.classfile.FieldElement

A marker interface for elements that can appear when traversing a FieldModel or be presented to a FieldBuilder.

22
22
java.lang.classfile.FieldTransform

A transformation on streams of FieldElement.

22
java.lang.classfile.Instruction

Models an executable instruction in a method body.

22
java.lang.classfile.Interfaces

Models the interfaces of a class.

22
java.lang.classfile.Label

A marker for a position within the instructions of a method body.

22
java.lang.classfile.MethodBuilder

A builder for methods.

22
java.lang.classfile.MethodElement

A marker interface for elements that can appear when traversing a MethodModel or be presented to a MethodBuilder.

22
22
java.lang.classfile.MethodSignature

Models the generic signature of a method, as defined by 4.7.9.

22
java.lang.classfile.MethodTransform

A transformation on streams of MethodElement.

22
java.lang.classfile.Opcode

Describes the opcodes of the JVM instruction set, as described in 6.5.

22
22
java.lang.classfile.PseudoInstruction

Models metadata about a CodeAttribute, such as entries in the exception table, line number table, local variable table, or the mapping between instructions and labels.

22
java.lang.classfile.Signature

Models generic Java type signatures, as defined in 4.7.9.1.

22
java.lang.classfile.Signature.ArrayTypeSig

Models the signature of an array type.

22
java.lang.classfile.Signature.BaseTypeSig

Models the signature of a primitive type or void

22
java.lang.classfile.Signature.ClassTypeSig

Models the signature of a possibly-parameterized class or interface type.

22
java.lang.classfile.Signature.RefTypeSig

Models the signature of a reference type, which may be a class, interface, type variable, or array type.

22
java.lang.classfile.Signature.ThrowableSig

Models a signature for a throwable type.

22
java.lang.classfile.Signature.TypeArg

Models the type argument.

23
java.lang.classfile.Signature.TypeArg.Bounded

Models a type argument with an explicit bound type.

23
java.lang.classfile.Signature.TypeArg.Bounded.WildcardIndicator

Models a type argument's wildcard indicator.

23
java.lang.classfile.Signature.TypeArg.Unbounded

Models an unbounded type argument *.

22
java.lang.classfile.Signature.TypeParam

Models a signature for a type parameter of a generic class or method.

22
java.lang.classfile.Signature.TypeVarSig

Models the signature of a type variable.

22
java.lang.classfile.Superclass

Models the superclass of a class.

22
java.lang.classfile.TypeAnnotation

Models an annotation on a type use, as defined in 4.7.19 and 4.7.20.

22
java.lang.classfile.TypeAnnotation.CatchTarget

Indicates that an annotation appears on the i'th type in an exception parameter declaration.

22
java.lang.classfile.TypeAnnotation.EmptyTarget

Indicates that an annotation appears on either the type in a field declaration, the return type of a method, the type of a newly constructed object, or the receiver type of a method or constructor.

22
java.lang.classfile.TypeAnnotation.FormalParameterTarget

Indicates that an annotation appears on the type in a formal parameter declaration of a method, constructor, or lambda expression.

22
java.lang.classfile.TypeAnnotation.LocalVarTarget

Indicates that an annotation appears on the type in a local variable declaration, including a variable declared as a resource in a try-with-resources statement.

22
java.lang.classfile.TypeAnnotation.LocalVarTargetInfo

Indicates a range of code array offsets within which a local variable has a value, and the index into the local variable array of the current frame at which that local variable can be found.

22
java.lang.classfile.TypeAnnotation.OffsetTarget

Indicates that an annotation appears on either the type in an instanceof expression or a new expression, or the type before the :: in a method reference expression.

22
java.lang.classfile.TypeAnnotation.SupertypeTarget

Indicates that an annotation appears on a type in the extends or implements clause of a class or interface declaration.

22
java.lang.classfile.TypeAnnotation.TargetInfo

Specifies which type in a declaration or expression is being annotated.

22
java.lang.classfile.TypeAnnotation.TargetType

The kind of target on which the annotation appears, as defined in 4.7.20.1.

22
java.lang.classfile.TypeAnnotation.ThrowsTarget

Indicates that an annotation appears on the i'th type in the throws clause of a method or constructor declaration.

22
java.lang.classfile.TypeAnnotation.TypeArgumentTarget

Indicates that an annotation appears either on the i'th type in a cast expression, or on the i'th type argument in the explicit type argument list for any of the following: a new expression, an explicit constructor invocation statement, a method invocation expression, or a method reference expression.

22
java.lang.classfile.TypeAnnotation.TypeParameterBoundTarget

Indicates that an annotation appears on the i'th bound of the j'th type parameter declaration of a generic class, interface, method, or constructor.

22
java.lang.classfile.TypeAnnotation.TypeParameterTarget

Indicates that an annotation appears on the declaration of the i'th type parameter of a generic class, generic interface, generic method, or generic constructor.

22
java.lang.classfile.TypeAnnotation.TypePathComponent

JVMS: Type_path structure identifies which part of the type is annotated, as defined in 4.7.20.2

22
22
java.lang.classfile.TypeKind

Describes the types that can be part of a field or method descriptor.

22
java.lang.classfile.WritableElement<
the type of the entity
T
>

A classfile element that can encode itself as a stream of bytes in the encoding expected by the classfile format.

22
java.lang.classfile.attribute

Provides interfaces describing classfile attributes for the java.lang.classfile library.

22
java.lang.classfile.attribute.AnnotationDefaultAttribute

Models the AnnotationDefault attribute 4.7.22, which can appear on methods of annotation types, and records the default value 9.6.2 for the element corresponding to this method.

22
java.lang.classfile.attribute.BootstrapMethodsAttribute

Models the BootstrapMethods attribute 4.7.23, which serves as an extension to the constant pool of a classfile.

22
22
java.lang.classfile.attribute.CharacterRangeTableAttribute

The CharacterRangeTable attribute is an optional variable-length attribute in the attributes table of a Code attribute.

22
java.lang.classfile.attribute.CodeAttribute

Models the Code attribute 4.7.3, appears on non-native, non-abstract methods and contains the bytecode of the method body.

22
java.lang.classfile.attribute.CompilationIDAttribute

Models the CompilationID attribute (@@@ need reference), which can appear on classes and records the compilation time of the class.

22
java.lang.classfile.attribute.ConstantValueAttribute

Models the ConstantValue attribute 4.7.2, which can appear on fields and indicates that the field's value is a constant.

22
java.lang.classfile.attribute.DeprecatedAttribute

Models the Deprecated attribute 4.7.15, which can appear on classes, methods, and fields.

22
java.lang.classfile.attribute.EnclosingMethodAttribute

Models the EnclosingMethod attribute 4.7.7, which can appear on classes, and indicates that the class is a local or anonymous class.

22
java.lang.classfile.attribute.ExceptionsAttribute

Models the Exceptions attribute 4.7.5, which can appear on methods, and records the exceptions declared to be thrown by this method.

22
22
java.lang.classfile.attribute.InnerClassesAttribute

Models the InnerClasses attribute 4.7.6, which can appear on classes, and records which classes referenced by this classfile are inner classes.

22
22
java.lang.classfile.attribute.LineNumberTableAttribute

Models the LineNumberTable attribute 4.7.12, which can appear on a Code attribute, and records the mapping between indexes into the code table and line numbers in the source file.

22
22
java.lang.classfile.attribute.LocalVariableTableAttribute

Models the LocalVariableTable attribute 4.7.13, which can appear on a Code attribute, and records debug information about local variables.

22
22
java.lang.classfile.attribute.LocalVariableTypeTableAttribute

Models the LocalVariableTypeTable attribute 4.7.14, which can appear on a Code attribute, and records debug information about local variables.

22
22
java.lang.classfile.attribute.MethodParametersAttribute

Models the MethodParameters attribute 4.7.24, which can appear on methods, and records optional information about the method's parameters.

22
java.lang.classfile.attribute.ModuleAttribute

Models the Module attribute 4.7.25, which can appear on classes that represent module descriptors.

22
22
java.lang.classfile.attribute.ModuleExportInfo

Models a single "exports" declaration in the ModuleAttribute.

22
java.lang.classfile.attribute.ModuleHashInfo

Models hash information for a single module in the ModuleHashesAttribute.

22
java.lang.classfile.attribute.ModuleHashesAttribute

Models the ModuleHashes attribute, which can appear on classes that represent module descriptors.

22
java.lang.classfile.attribute.ModuleMainClassAttribute

Models the ModuleMainClass attribute 4.7.27, which can appear on classes that represent module descriptors.

22
java.lang.classfile.attribute.ModuleOpenInfo

Models a single "opens" declaration in the ModuleAttribute.

22
java.lang.classfile.attribute.ModulePackagesAttribute

Models the ModulePackages attribute 4.7.26, which can appear on classes that represent module descriptors.

22
java.lang.classfile.attribute.ModuleProvideInfo

Models a single "provides" declaration in the ModuleAttribute.

22
java.lang.classfile.attribute.ModuleRequireInfo

Models a single "requires" declaration in the ModuleAttribute.

22
java.lang.classfile.attribute.ModuleResolutionAttribute

Models the ModuleResolution attribute, which can appear on classes that represent module descriptors.

22
java.lang.classfile.attribute.ModuleTargetAttribute

Models the ModuleTarget attribute, which can appear on classes that represent module descriptors.

22
java.lang.classfile.attribute.NestHostAttribute

Models the NestHost attribute 4.7.28, which can appear on classes to indicate that this class is a member of a nest.

22
java.lang.classfile.attribute.NestMembersAttribute

Models the NestMembers attribute 4.7.29, which can appear on classes to indicate that this class is the host of a nest.

22
java.lang.classfile.attribute.PermittedSubclassesAttribute

Models the PermittedSubclasses attribute 4.7.31, which can appear on classes to indicate which classes may extend this class.

22
java.lang.classfile.attribute.RecordAttribute

Models the Record attribute 4.7.30, which can appear on classes to indicate that this class is a record class.

22
22
java.lang.classfile.attribute.RuntimeInvisibleAnnotationsAttribute

Models the RuntimeInvisibleAnnotations attribute 4.7.17, which can appear on classes, methods, and fields.

22
java.lang.classfile.attribute.RuntimeInvisibleParameterAnnotationsAttribute

Models the RuntimeInvisibleParameterAnnotations attribute 4.7.19, which can appear on methods.

22
java.lang.classfile.attribute.RuntimeInvisibleTypeAnnotationsAttribute

Models the RuntimeInvisibleTypeAnnotations attribute 4.7.21, which can appear on classes, methods, fields, and code attributes.

22
java.lang.classfile.attribute.RuntimeVisibleAnnotationsAttribute

Models the RuntimeVisibleAnnotations attribute 4.7.16, which can appear on classes, methods, and fields.

22
java.lang.classfile.attribute.RuntimeVisibleParameterAnnotationsAttribute

Models the RuntimeVisibleParameterAnnotations attribute 4.7.18, which can appear on methods.

22
java.lang.classfile.attribute.RuntimeVisibleTypeAnnotationsAttribute

Models the RuntimeVisibleTypeAnnotations attribute 4.7.20, which can appear on classes, methods, fields, and code attributes.

22
java.lang.classfile.attribute.SignatureAttribute

Models the Signature attribute 4.7.9, which can appear on classes, methods, or fields.

22
java.lang.classfile.attribute.SourceDebugExtensionAttribute

Models the SourceDebugExtension attribute.

22
java.lang.classfile.attribute.SourceFileAttribute

Models the SourceFile attribute 4.7.10, which can appear on classes.

22
java.lang.classfile.attribute.SourceIDAttribute

Models the SourceID attribute, which can appear on classes.

22
java.lang.classfile.attribute.StackMapFrameInfo

Models stack map frame of StackMapTable attribute 4.7.4.

22
22
22
22
22
java.lang.classfile.attribute.StackMapTableAttribute

Models the StackMapTable attribute 4.7.4, which can appear on a Code attribute.

22
java.lang.classfile.attribute.SyntheticAttribute

Models the Synthetic attribute 4.7.8, which can appear on classes, methods, and fields.

22
java.lang.classfile.attribute.UnknownAttribute

Models an unknown attribute on a class, method, or field.

22
java.lang.classfile.components

Provides specific components, transformations, and tools built on top of the java.lang.classfile library.

22
java.lang.classfile.components.ClassPrinter

A printer of classfiles and its elements.

22
java.lang.classfile.components.ClassPrinter.LeafNode

A leaf node holding single printable value.

22
java.lang.classfile.components.ClassPrinter.ListNode

A tree node holding List of nested nodes.

22
java.lang.classfile.components.ClassPrinter.MapNode

A tree node holding Map of nested nodes.

22
java.lang.classfile.components.ClassPrinter.Node

Named, traversable, and printable node parent.

22
java.lang.classfile.components.ClassPrinter.Verbosity

Level of detail to print or export.

22
java.lang.classfile.components.ClassRemapper

ClassRemapper is a ClassTransform, FieldTransform, MethodTransform and CodeTransform deeply re-mapping all class references in any form, according to given map or map function.

22
java.lang.classfile.components.CodeLocalsShifter

CodeLocalsShifter is a CodeTransform shifting locals to newly allocated positions to avoid conflicts during code injection.

22
java.lang.classfile.components.CodeRelabeler

A code relabeler is a CodeTransform replacing all occurrences of java.lang.classfile.Label in the transformed code with new instances.

22
java.lang.classfile.components.CodeStackTracker

CodeStackTracker is a CodeTransform tracking stack content and calculating max stack size.

22
java.lang.classfile.constantpool

Provides interfaces describing classfile constant pool entries for the java.lang.classfile library.

22
java.lang.classfile.constantpool.AnnotationConstantValueEntry

A constant pool entry that may be used as an annotation constant, which includes the four kinds of primitive constants, and UTF8 constants.

22
java.lang.classfile.constantpool.ClassEntry

Models a CONSTANT_Class_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.ConstantDynamicEntry

Models a CONSTANT_Dynamic_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.ConstantPool

Provides read access to the constant pool and bootstrap method table of a classfile.

22
java.lang.classfile.constantpool.ConstantPoolBuilder

Builder for the constant pool of a classfile.

22
java.lang.classfile.constantpool.ConstantPoolException

Thrown to indicate that requested entry cannot be obtained from the constant pool.

22
java.lang.classfile.constantpool.ConstantValueEntry

Models a constant pool entry that can be used as the constant in a ConstantValue attribute; this includes the four primitive constant types and String constants.

22
java.lang.classfile.constantpool.DoubleEntry

Models a CONSTANT_Double_info constant in the constant pool of a classfile.

22
22
java.lang.classfile.constantpool.FieldRefEntry

Models a CONSTANT_Fieldref_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.FloatEntry

Models a CONSTANT_Float_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.IntegerEntry

Models a CONSTANT_Integer_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.InterfaceMethodRefEntry

Models a CONSTANT_InterfaceMethodRef_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.InvokeDynamicEntry

Models a constant pool entry for a dynamic call site.

22
java.lang.classfile.constantpool.LoadableConstantEntry

Marker interface for constant pool entries suitable for loading via the LDC instructions.

22
java.lang.classfile.constantpool.LongEntry

Models a CONSTANT_Long_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.MemberRefEntry

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

22
java.lang.classfile.constantpool.MethodHandleEntry

Models a CONSTANT_MethodHandle_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.MethodRefEntry

Models a CONSTANT_MethodRef_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.MethodTypeEntry

Models a CONSTANT_MethodType_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.ModuleEntry

Models a CONSTANT_Module_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.NameAndTypeEntry

Models a CONSTANT_NameAndType_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.PackageEntry

Models a CONSTANT_Package_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.PoolEntry

Models an entry in the constant pool of a classfile.

22
java.lang.classfile.constantpool.StringEntry

Models a CONSTANT_String_info constant in the constant pool of a classfile.

22
java.lang.classfile.constantpool.Utf8Entry

Models a CONSTANT_UTF8_info constant in the constant pool of a classfile.

22
java.lang.classfile.instruction

Provides interfaces describing code instructions for the java.lang.classfile library.

22
java.lang.classfile.instruction.ArrayLoadInstruction

Models an array load instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.ArrayStoreInstruction

Models an array store instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.BranchInstruction

Models a branching instruction (conditional or unconditional) in the code array of a Code attribute.

22
java.lang.classfile.instruction.CharacterRange

A pseudo-instruction which models a single entry in the CharacterRangeTableAttribute.

22
java.lang.classfile.instruction.ConstantInstruction

Models a constant-load instruction in the code array of a Code attribute, including "intrinsic constant" instructions (e.g., iconst_0), "argument constant" instructions (e.g., bipush), and "load constant" instructions (e.g., LDC).

22
java.lang.classfile.instruction.ConstantInstruction.ArgumentConstantInstruction

Models an "argument constant" instruction (e.g., bipush).

22
java.lang.classfile.instruction.ConstantInstruction.IntrinsicConstantInstruction

Models an "intrinsic constant" instruction (e.g., iconst_0).

22
java.lang.classfile.instruction.ConstantInstruction.LoadConstantInstruction

Models a "load constant" instruction (e.g., ldc).

22
java.lang.classfile.instruction.ConvertInstruction

Models a primitive conversion instruction in the code array of a Code attribute, such as i2l.

22
java.lang.classfile.instruction.DiscontinuedInstruction

Models instruction discontinued from the code array of a Code attribute.

22
java.lang.classfile.instruction.DiscontinuedInstruction.JsrInstruction

Models JSR and JSR_W instructions discontinued from the code array of a Code attribute since class file version 51.0.

22
java.lang.classfile.instruction.DiscontinuedInstruction.RetInstruction

Models RET and RET_W instructions discontinued from the code array of a Code attribute since class file version 51.0.

22
java.lang.classfile.instruction.ExceptionCatch

A pseudo-instruction modeling an entry in the exception table of a code attribute.

22
java.lang.classfile.instruction.FieldInstruction

Models a field access instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.IncrementInstruction

Models a local variable increment instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.InvokeDynamicInstruction

Models an invokedynamic instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.InvokeInstruction

Models a method invocation instruction in the code array of a Code attribute, other than invokedynamic.

22
java.lang.classfile.instruction.LabelTarget

A pseudo-instruction which indicates that the specified label corresponds to the current position in the Code attribute.

22
java.lang.classfile.instruction.LineNumber

A pseudo-instruction which models a single entry in the LineNumberTableAttribute.

22
java.lang.classfile.instruction.LoadInstruction

Models a local variable load instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.LocalVariable

A pseudo-instruction which models a single entry in the LocalVariableTableAttribute.

22
java.lang.classfile.instruction.LocalVariableType

A pseudo-instruction which models a single entry in the LocalVariableTypeTableAttribute.

22
java.lang.classfile.instruction.LookupSwitchInstruction

Models a lookupswitch instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.MonitorInstruction

Models a monitorenter or monitorexit instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.NewMultiArrayInstruction

Models a multianewarray invocation instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.NewObjectInstruction

Models a new instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.NewPrimitiveArrayInstruction

Models a newarray invocation instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.NewReferenceArrayInstruction

Models a anewarray invocation instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.NopInstruction

Models a nop invocation instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.OperatorInstruction

Models an arithmetic operator instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.ReturnInstruction

Models a return-from-method instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.StackInstruction

Models a stack manipulation instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.StoreInstruction

Models a local variable store instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.SwitchCase

Models a single case in a lookupswitch or tableswitch instruction.

22
java.lang.classfile.instruction.TableSwitchInstruction

Models a tableswitch instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.ThrowInstruction

Models an athrow instruction in the code array of a Code attribute.

22
java.lang.classfile.instruction.TypeCheckInstruction

Models an instanceof or checkcast instruction in the code array of a Code attribute.

Implicitly Declared Classes and Instance Main Methods (Third Preview of JEP 477) Summary

SincePreview Item and Description
23

Returns:

This console
java.io.Console.println
(Object
An object whose string representation is to be written, may be null.
obj
)

Writes a string representation of the specified object to this console's output stream, terminates the line using System#lineSeparator() and then flushes the console.

23

Returns:

A string containing the line read from the console, not including any line-termination characters, or null if an end of stream has been reached without having read any characters.
java.io.Console.readln
(String
A prompt string, may be null.
prompt
)

Writes a prompt as if by calling print, then reads a single line of text from this console.

23
java.io.IO

A collection of static convenience methods that provide access to system console for implicitly declared classes.

Language Model Summary

SincePreview Item and Description
23
javax.lang.model.util.AbstractAnnotationValueVisitorPreview<
the return type of this visitor's methods
R
,
the type of the additional parameter to this visitor's methods.
P
>

A skeletal visitor for annotation values with default behavior appropriate for a preview source version.

23
javax.lang.model.util.AbstractElementVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A skeletal visitor of program elements with default behavior appropriate for a preview source version.

23
javax.lang.model.util.AbstractTypeVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A skeletal visitor of types with default behavior appropriate for a preview source version.

23
javax.lang.model.util.ElementKindVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A visitor of program elements based on their kind with default behavior appropriate for a preview source version.

23
javax.lang.model.util.ElementScannerPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A scanning visitor of program elements with default behavior appropriate for a preview source version.

23
javax.lang.model.util.SimpleAnnotationValueVisitorPreview<
the return type of this visitor's methods
R
,
the type of the additional parameter to this visitor's methods.
P
>

A simple visitor for annotation values with default behavior appropriate for a preview source version.

23
javax.lang.model.util.SimpleElementVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A simple visitor of program elements with default behavior appropriate for a preview source version.

23
javax.lang.model.util.SimpleTypeVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A simple visitor of types with default behavior appropriate for a preview source version.

23
javax.lang.model.util.TypeKindVisitorPreview<
the return type of this visitor's methods. Use Void for visitors that do not need to return results.
R
,
the type of the additional parameter to this visitor's methods. Use Void for visitors that do not need an additional parameter.
P
>

A visitor of types based on their kind with default behavior appropriate for a preview source version.

Module Import Declarations (Preview of JEP 476) Summary

SincePreview Item and Description
23

Returns:

true if this is an module import declaration.
com.sun.source.tree.ImportTree.isModule
()

Returns true if this is an module import declaration.

23

Scoped Values (Third Preview of JEP 481) Summary

SincePreview Item and Description
21
java.lang.ScopedValue<
the type of the value
T
>

A value that may be safely and efficiently shared to methods without using method parameters.

23
java.lang.ScopedValue.CallableOp<
result type of the operation
T
,
type of the exception thrown by the operation
X extends Throwable
>

An operation that returns a result and may throw an exception.

21
java.lang.ScopedValue.Carrier

A mapping of scoped values, as keys, to values.

Stream Gatherers (Second Preview of JEP 473) Summary

SincePreview Item and Description
22
java.util.stream.Gatherer<
the type of input elements to the gatherer operation
T
,
the potentially mutable state type of the gatherer operation (often hidden as an implementation detail)
A
,
the type of output elements from the gatherer operation
R
>

An intermediate operation that transforms a stream of input elements into a stream of output elements, optionally applying a final action when the end of the upstream is reached.

22
java.util.stream.Gatherer.Downstream<
the type of elements this downstream accepts
T
>

A Downstream object is the next stage in a pipeline of operations, to which elements can be sent.

22
java.util.stream.Gatherer.Integrator<
the type of state used by this integrator
A
,
the type of elements this integrator consumes
T
,
the type of results this integrator can produce
R
>

An Integrator receives elements and processes them, optionally using the supplied state, and optionally sends incremental results downstream.

22
java.util.stream.Gatherer.Integrator.Greedy<
the type of state used by this integrator
A
,
the type of elements this greedy integrator receives
T
,
the type of results this greedy integrator can produce
R
>

Greedy Integrators consume all their input, and may only relay that the downstream does not want more elements.

22
java.util.stream.Gatherers

Implementations of Gatherer that provide useful intermediate operations, such as windowing functions, folding functions, transforming elements concurrently, etc.

22

Returns:

the new stream
java.util.stream.Stream.gather
(Gatherer<? super T, ?, R>
a gatherer
gatherer
)

Returns a stream consisting of the results of applying the given Gatherer to the elements of this stream.

Structured Concurrency (Third Preview of JEP 480) Summary

SincePreview Item and Description
21
java.util.concurrent.StructureViolationException

Thrown when a structure violation is detected.

21
java.util.concurrent.StructuredTaskScope<
the result type of tasks executed in the task scope
T
>

A basic API for structured concurrency.

21
java.util.concurrent.StructuredTaskScope.ShutdownOnFailure

A StructuredTaskScope that captures the exception of the first subtask to fail.

21
java.util.concurrent.StructuredTaskScope.ShutdownOnSuccess<
the result type
T
>

A StructuredTaskScope that captures the result of the first subtask to complete successfully.

21
java.util.concurrent.StructuredTaskScope.Subtask<
the result type
T
>

Represents a subtask forked with fork(Callable).

21