public static class AgentBuilder.RedefinitionStrategy.Collector.ForRedefinition extends Object implements AgentBuilder.RedefinitionStrategy.Collector
| Modifier and Type | Class and Description |
|---|---|
protected static class |
AgentBuilder.RedefinitionStrategy.Collector.ForRedefinition.Entry
An entry describing a type redefinition.
|
AgentBuilder.RedefinitionStrategy.Collector.ForRedefinition, AgentBuilder.RedefinitionStrategy.Collector.ForRetransformation| Modifier | Constructor and Description |
|---|---|
protected |
ForRedefinition(AgentBuilder.Default.Transformation transformation)
Creates a new collector for a redefinition.
|
| Modifier and Type | Method and Description |
|---|---|
void |
apply(Instrumentation instrumentation,
ByteBuddy byteBuddy,
AgentBuilder.BinaryLocator binaryLocator,
AgentBuilder.TypeStrategy typeStrategy,
AgentBuilder.Listener listener,
AgentBuilder.Default.NativeMethodStrategy nativeMethodStrategy,
AccessControlContext accessControlContext,
AgentBuilder.InitializationStrategy initializationStrategy,
AgentBuilder.Default.BootstrapInjectionStrategy bootstrapInjectionStrategy)
Applies the represented type modification on all collected types.
|
boolean |
consider(Class<?> type)
Considers a loaded class for modification.
|
String |
toString() |
protected ForRedefinition(AgentBuilder.Default.Transformation transformation)
transformation - The transformation of the built agent.public boolean consider(Class<?> type)
AgentBuilder.RedefinitionStrategy.Collectorconsider in interface AgentBuilder.RedefinitionStrategy.Collectortype - The type that is to be considered.true if the class is considered to be redefined.public void apply(Instrumentation instrumentation, ByteBuddy byteBuddy, AgentBuilder.BinaryLocator binaryLocator, AgentBuilder.TypeStrategy typeStrategy, AgentBuilder.Listener listener, AgentBuilder.Default.NativeMethodStrategy nativeMethodStrategy, AccessControlContext accessControlContext, AgentBuilder.InitializationStrategy initializationStrategy, AgentBuilder.Default.BootstrapInjectionStrategy bootstrapInjectionStrategy) throws UnmodifiableClassException, ClassNotFoundException
AgentBuilder.RedefinitionStrategy.Collectorapply in interface AgentBuilder.RedefinitionStrategy.Collectorinstrumentation - The instrumentation to use.byteBuddy - The Byte Buddy configuration to use.binaryLocator - The binary locator to use.typeStrategy - The type strategy to use.listener - The listener to report to.nativeMethodStrategy - The native method strategy to apply.accessControlContext - The access control context to use.initializationStrategy - The initialization strategy to use.bootstrapInjectionStrategy - The bootrstrap injection strategy to use.UnmodifiableClassException - If an unmodifiable class is attempted to be modified.ClassNotFoundException - If a class cannot be found while redefining another class.Copyright © 2014–2015. All rights reserved.