Enum Class AgentBuilder.InjectionStrategy.UsingReflection

java.lang.Object
java.lang.Enum<AgentBuilder.InjectionStrategy.UsingReflection>
net.bytebuddy.agent.builder.AgentBuilder.InjectionStrategy.UsingReflection
All Implemented Interfaces:
Serializable, Comparable<AgentBuilder.InjectionStrategy.UsingReflection>, Constable, AgentBuilder.InjectionStrategy
Enclosing interface:
AgentBuilder.InjectionStrategy

public static enum AgentBuilder.InjectionStrategy.UsingReflection extends Enum<AgentBuilder.InjectionStrategy.UsingReflection> implements AgentBuilder.InjectionStrategy
An injection strategy that uses Java reflection. This strategy is not capable of injecting classes into the bootstrap class loader.
  • Enum Constant Details

  • Constructor Details

    • UsingReflection

      private UsingReflection()
  • Method Details

    • values

      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • resolve

      public ClassInjector resolve(@MaybeNull ClassLoader classLoader, @MaybeNull ProtectionDomain protectionDomain)
      Resolves the class injector to use for a given class loader and protection domain.
      Specified by:
      resolve in interface AgentBuilder.InjectionStrategy
      Parameters:
      classLoader - The class loader to use or null if using the bootstrap loader.
      protectionDomain - The protection domain to use or null if all privileges should be assigned.
      Returns:
      The class injector to use.