Class Bytecode
java.lang.Object
de.iip_ecosphere.platform.support.bytecode.Bytecode
Generic access to Bytecode manipulation. Requires an implementing plugin of type
Bytecode or an active
BytecodeProviderDescriptor. Abstraction based on bytebuddy.- Author:
- Holger Eichelberger, SSE
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceBuilds a dynamic class. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract <T> Bytecode.ClassBuilder<T> createClassBuilder(String name, Class<T> cls, ClassLoader loader) Creates a class builder for a dynamic class.static BytecodeReturns the Rest instance.static voidsetInstance(Bytecode rest) Manually sets the instance.
-
Field Details
-
instance
-
-
Constructor Details
-
Bytecode
public Bytecode()
-
-
Method Details
-
getInstance
Returns the Rest instance.- Returns:
- the instance
-
setInstance
Manually sets the instance. Shall not be needed, but may be required in some tests.- Parameters:
rest- the Rest instance
-
createClassBuilder
public abstract <T> Bytecode.ClassBuilder<T> createClassBuilder(String name, Class<T> cls, ClassLoader loader) Creates a class builder for a dynamic class.- Type Parameters:
T- the type the dynamic class shall interit from- Parameters:
name- the name of the classcls- type the dynamic class shall interit fromloader- the class loader the class shall be loaded by and made available through- Returns:
- the class builder for further setuo
-