Class AbstractInvocationHandler
java.lang.Object
io.camunda.zeebe.spring.test.proxy.AbstractInvocationHandler
- All Implemented Interfaces:
InvocationHandler
- Direct Known Subclasses:
ZeebeClientProxy,ZeebeTestEngineProxy
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanBy default delegates toObject.equals(java.lang.Object)so instances are only equal if they are identical.protected abstract ObjecthandleInvocation(Object proxy, Method method, @Nullable Object[] args) invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])delegates to this method upon any method invocation on the proxy instance, exceptObject.equals(java.lang.Object),Object.hashCode()andObject.toString().inthashCode()By default delegates toObject.hashCode().final ObjecttoString()By default delegates toObject.toString().
-
Constructor Details
-
AbstractInvocationHandler
public AbstractInvocationHandler()
-
-
Method Details
-
invoke
@CheckForNull public final Object invoke(Object proxy, Method method, @CheckForNull @Nullable Object[] args) throws Throwable - Specified by:
invokein interfaceInvocationHandler- Throws:
Throwable
-
handleInvocation
@CheckForNull protected abstract Object handleInvocation(Object proxy, Method method, @Nullable Object[] args) throws Throwable invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])delegates to this method upon any method invocation on the proxy instance, exceptObject.equals(java.lang.Object),Object.hashCode()andObject.toString(). The result will be returned as the proxied method's return value.Unlike
invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[]),argswill never be null. When the method has no parameter, an empty array is passed in.- Throws:
Throwable
-
equals
By default delegates toObject.equals(java.lang.Object)so instances are only equal if they are identical.proxy.equals(argument)returns true if:proxyandargumentare of the same type- and this method returns true for the
InvocationHandlerofargument
Subclasses can override this method to provide custom equality.
-
hashCode
public int hashCode()By default delegates toObject.hashCode(). The dynamic proxies'hashCode()will delegate to this method. Subclasses can override this method to provide custom equality. -
toString
By default delegates toObject.toString(). The dynamic proxies'toString()will delegate to this method. Subclasses can override this method to provide custom string representation for the proxies.
-