Package net.bytebuddy.agent.builder
Enum AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating
- java.lang.Object
-
- java.lang.Enum<AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating>
-
- net.bytebuddy.agent.builder.AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating>
,AgentBuilder.RedefinitionStrategy.DiscoveryStrategy
- Enclosing interface:
- AgentBuilder.RedefinitionStrategy.DiscoveryStrategy
public static enum AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating extends java.lang.Enum<AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating> implements AgentBuilder.RedefinitionStrategy.DiscoveryStrategy
A discovery strategy that considers all loaded types supplied byInstrumentation.getAllLoadedClasses()
. For each reiteration, this strategy checks if additional types were loaded after the previously supplied types. Doing so, types that were loaded during instrumentations can be retransformed as such types are not passed to any class file transformer.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating.ReiteratingIterable
An iterable that returns any loaded types and checks if any additional types were loaded during the last instrumentation.protected static class
AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating.ReiteratingIterator
A reiterating iterator that considers types that were loaded during an instrumentation.-
Nested classes/interfaces inherited from interface net.bytebuddy.agent.builder.AgentBuilder.RedefinitionStrategy.DiscoveryStrategy
AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Explicit, AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating, AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.SinglePass
-
-
Enum Constant Summary
Enum Constants Enum Constant Description INSTANCE
The singleton instance.
-
Constructor Summary
Constructors Modifier Constructor Description private
Reiterating()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Iterable<java.lang.Iterable<java.lang.Class<?>>>
resolve(java.lang.instrument.Instrumentation instrumentation)
Resolves an iterable of types to retransform.static AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
INSTANCE
public static final AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating INSTANCE
The singleton instance.
-
-
Method Detail
-
values
public static AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating c : AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static AgentBuilder.RedefinitionStrategy.DiscoveryStrategy.Reiterating valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
resolve
public java.lang.Iterable<java.lang.Iterable<java.lang.Class<?>>> resolve(java.lang.instrument.Instrumentation instrumentation)
Resolves an iterable of types to retransform. Types might be loaded during a previous retransformation which might require multiple passes for a retransformation.- Specified by:
resolve
in interfaceAgentBuilder.RedefinitionStrategy.DiscoveryStrategy
- Parameters:
instrumentation
- The instrumentation instance used for the redefinition.- Returns:
- An iterable of types to consider for retransformation.
-
-