Interface TypeProxy.InvocationFactory

All Known Implementing Classes:
TypeProxy.InvocationFactory.Default
Enclosing class:
TypeProxy

public static interface TypeProxy.InvocationFactory
An invocation factory is responsible for creating a special method invocation for any method that is to be invoked. These special method invocations are then implemented by the TypeProxy. Illegal Implementation.SpecialMethodInvocation are implemented by throwing an AbstractMethodError.
  • Method Details

    • invoke

      Implementation.SpecialMethodInvocation invoke(Implementation.Target implementationTarget, TypeDescription proxiedType, MethodDescription instrumentedMethod)
      Creates a special method invocation to implement for a given method.
      Parameters:
      implementationTarget - The implementation target the type proxy is created for.
      proxiedType - The type for the type proxy to subclass or implement.
      instrumentedMethod - The instrumented method that is to be invoked.
      Returns:
      A special method invocation of the given method or an illegal invocation if the proxy should throw an AbstractMethodError when the instrumented method is invoked.