Uses of Interface
java.lang.classfile.CodeTransform
Package
Description
Provides classfile parsing, generation, and transformation library.
Provides specific components, transformations, and tools built on top of the
java.lang.classfile
library.-
Uses of CodeTransform in java.lang.classfile
Modifier and TypeFieldDescriptionstatic final CodeTransform
CodeTransform.ACCEPT_ALL
A code transform that sends all elements to the builder.Modifier and TypeMethodDescriptiondefault CodeTransform
CodeTransform.andThen
(CodeTransform t) static CodeTransform
CodeTransform.endHandler
(Consumer<CodeBuilder> finisher) Create a code transform that passes each element through to the builder, and calls the specified function when transformation is complete.static CodeTransform
CodeTransform.ofStateful
(Supplier<CodeTransform> supplier) Create a stateful code transform from aSupplier
.Modifier and TypeMethodDescriptiondefault CodeTransform
CodeTransform.andThen
(CodeTransform t) MethodBuilder.transformCode
(CodeModel code, CodeTransform transform) Build the method body for this method by transforming the body of another method.default CodeBuilder
CodeBuilder.transforming
(CodeTransform transform, Consumer<CodeBuilder> handler) Apply a transform to the code built by a handler, directing results to this builder.static MethodTransform
MethodTransform.transformingCode
(CodeTransform xform) Create a method transform that transformsCodeModel
elements with the supplied code transform.static ClassTransform
ClassTransform.transformingMethodBodies
(CodeTransform xform) Create a class transform that transforms theCodeAttribute
(method body) ofMethodModel
elements with the supplied code transform.static ClassTransform
ClassTransform.transformingMethodBodies
(Predicate<MethodModel> filter, CodeTransform xform) Create a class transform that transforms theCodeAttribute
(method body) ofMethodModel
elements with the supplied code transform.Modifier and TypeMethodDescriptionstatic CodeTransform
CodeTransform.ofStateful
(Supplier<CodeTransform> supplier) Create a stateful code transform from aSupplier
. -
Uses of CodeTransform in java.lang.classfile.components
Modifier and TypeInterfaceDescriptioninterface
CodeLocalsShifter
is aCodeTransform
shifting locals to newly allocated positions to avoid conflicts during code injection.interface
A code relabeler is aCodeTransform
replacing all occurrences ofLabel
in the transformed code with new instances.interface
CodeStackTracker
is aCodeTransform
tracking stack content and calculating max stack size.Modifier and TypeMethodDescriptionClassRemapper.asCodeTransform()
Returns thisClassRemapper
asCodeTransform
instance.