com.agical.rmock.core
Interface MethodHandle
- All Known Implementing Classes:
- ForwardingMethodHandle, InterfaceMethodHandle
public interface MethodHandle
A method handle represents an actual method implementation. Method handles
are useful when creating intercepted objects or mocking concrete classes so that the actual
implementation can be accessed an used from an action.
It also provides meta-data about the method that can be used to verify
modifications etc.
(c) Agical AB 2005
- Author:
- joakim.ohlrogge
getReturnType
java.lang.Class getReturnType()
- Returns:
- The return type of this method
getParameterTypes
java.lang.Class[] getParameterTypes()
- Returns:
- the types of the arguments for this method.
invoke
java.lang.Object invoke(java.lang.Object[] args)
throws java.lang.Throwable
- Invokes the method
- Parameters:
args
- The arguments to use
- Returns:
- the object returned by the method
- Throws:
any
- exception thrown by the method
java.lang.Throwable
Copyright © 2005-2011 Agical AB. All Rights Reserved.