Class DefaultClassTransformerRegistry
java.lang.Object
eu.cloudnetservice.wrapper.transform.DefaultClassTransformerRegistry
- All Implemented Interfaces:
ClassTransformerRegistry
@Singleton
public final class DefaultClassTransformerRegistry
extends Object
implements ClassTransformerRegistry
The default implementation of a class transformer registry.
- Since:
- 4.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final recordAn implementation of a class file transformer that parses and transforms class files using the given CloudNet transformer. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Instrumentationprivate static final org.slf4j.Logger -
Constructor Summary
ConstructorsConstructorDescriptionDefaultClassTransformerRegistry(@NonNull Instrumentation instrumentation) Constructs a new default transformer registry using the given instrumentation. -
Method Summary
Modifier and TypeMethodDescriptionvoidregisterTransformer(@NonNull ClassTransformer transformer) Registers the given transformer into this registry.
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
instrumentation
-
-
Constructor Details
-
DefaultClassTransformerRegistry
Constructs a new default transformer registry using the given instrumentation.- Parameters:
instrumentation- the instrumentation to use to register class transformers.- Throws:
NullPointerException- if the given instrumentation instance is null.
-
-
Method Details
-
registerTransformer
Registers the given transformer into this registry. There is no guarantee that calling this method with the same transformer twice will result in a single registration.- Specified by:
registerTransformerin interfaceClassTransformerRegistry- Parameters:
transformer- the transformer to register into this registry.
-