protected static interface ClassReloadingStrategy.Dispatcher
| Modifier and Type | Interface and Description |
|---|---|
static class |
ClassReloadingStrategy.Dispatcher.CreationAction
An action to create an appropriate
ClassReloadingStrategy.Dispatcher. |
static class |
ClassReloadingStrategy.Dispatcher.ForJava6CapableVm
A dispatcher for a Java 6 capable VM that is potentially capable of retransformation.
|
static class |
ClassReloadingStrategy.Dispatcher.ForLegacyVm
A dispatcher for a legacy VM that does not support retransformation.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addTransformer(java.lang.instrument.Instrumentation instrumentation,
java.lang.instrument.ClassFileTransformer classFileTransformer,
boolean canRetransform)
Registers a transformer.
|
boolean |
isModifiableClass(java.lang.instrument.Instrumentation instrumentation,
java.lang.Class<?> type)
Invokes the
Instrumentation#isModifiableClass method. |
boolean |
isRetransformClassesSupported(java.lang.instrument.Instrumentation instrumentation)
Invokes the
Instrumentation#isRetransformClassesSupported method. |
void |
retransformClasses(java.lang.instrument.Instrumentation instrumentation,
java.lang.Class<?>[] type)
Retransforms the supplied classes.
|
boolean isModifiableClass(java.lang.instrument.Instrumentation instrumentation,
java.lang.Class<?> type)
Instrumentation#isModifiableClass method.instrumentation - The instrumentation instance to invoke the method on.type - The type to consider for modifiability.true if the supplied type can be modified.boolean isRetransformClassesSupported(java.lang.instrument.Instrumentation instrumentation)
Instrumentation#isRetransformClassesSupported method.instrumentation - The instrumentation instance to invoke the method on.true if the supplied instrumentation instance supports retransformation.void addTransformer(java.lang.instrument.Instrumentation instrumentation,
java.lang.instrument.ClassFileTransformer classFileTransformer,
boolean canRetransform)
instrumentation - The instrumentation instance to invoke the method on.classFileTransformer - The class file transformer to register.canRetransform - true if the class file transformer should be invoked upon a retransformation.void retransformClasses(java.lang.instrument.Instrumentation instrumentation,
java.lang.Class<?>[] type)
throws java.lang.instrument.UnmodifiableClassException
instrumentation - The instrumentation instance to invoke the method on.type - The types to retransform.java.lang.instrument.UnmodifiableClassException - If any of the supplied types are unmodifiable.