Interface ProxyConfiguration.Interceptor

  • All Known Implementing Classes:
    ByteBuddyInterceptor
    Enclosing interface:
    ProxyConfiguration

    public static interface ProxyConfiguration.Interceptor
    An interceptor object that is responsible for invoking a proxy's method.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.Object intercept​(java.lang.Object instance, java.lang.reflect.Method method, java.lang.Object[] arguments)
      Intercepts a method call to a proxy.
    • Method Detail

      • intercept

        @RuntimeType
        java.lang.Object intercept​(@This
                                   java.lang.Object instance,
                                   @Origin
                                   java.lang.reflect.Method method,
                                   @AllArguments
                                   java.lang.Object[] arguments)
                            throws java.lang.Throwable
        Intercepts a method call to a proxy.
        Parameters:
        instance - The proxied instance.
        method - The invoked method.
        arguments - The intercepted method arguments.
        Returns:
        The method's return value.
        Throws:
        java.lang.Throwable - If the intercepted method raises an exception.