Module java.base

Interface CodeModel

All Superinterfaces:
AttributedElementPREVIEW, ClassFileElementPREVIEW, CompoundElementPREVIEW<CodeElementPREVIEW>, Iterable<CodeElementPREVIEW>, MethodElementPREVIEW
All Known Subinterfaces:
CodeAttributePREVIEW

public sealed interface CodeModel extends CompoundElementPREVIEW<CodeElementPREVIEW>, AttributedElementPREVIEW, MethodElementPREVIEW permits CodeAttributePREVIEW (not exhaustive)
CodeModel is a preview API of the Java platform.
Programs can only use CodeModel 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 body of a method (the Code attribute). The instructions of the method body are accessed via a streaming view (e.g., CompoundElement.elements()PREVIEW).
Since:
22