public interface ClassInjector
This class is internal and is hence not for public use. Its APIs are unstable and can change at any time.
  • Method Details

    • proxyBuilder

      ProxyInjectionBuilder proxyBuilder(String classToProxy, String newProxyName)
      Create a builder for a proxy class which will be injected into the instrumented ClassLoader. The generated proxy will delegate to the original class, which is loaded in a separate classloader.

      This removes the need for the proxied class and its dependencies to be visible (just like Advices) to the instrumented ClassLoader.

      Parameters:
      classToProxy - the fully qualified name of the class for which a proxy will be generated
      newProxyName - the fully qualified name to use for the generated proxy
      Returns:
      a builder for further customizing the proxy. ProxyInjectionBuilder.inject(InjectionMode) must be called to actually inject the proxy.
    • proxyBuilder

      default ProxyInjectionBuilder proxyBuilder(String classToProxy)
      Same as invoking proxyBuilder(String, String), but the resulting proxy will have the same name as the proxied class.
      Parameters:
      classToProxy - the fully qualified name of the class for which a proxy will be generated
      Returns:
      a builder for further customizing and injecting the proxy