Clover coverage report - Maven Clover report
Coverage timestamp: Sun Mar 18 2007 17:42:32 CET
file stats: LOC: 54   Methods: 4
NCLOC: 27   Classes: 1
 
 Source file Conditionals Statements Methods TOTAL
InterfaceMethodHandle.java - 100% 100% 100%
coverage
 1    package com.agical.rmock.core.util;
 2   
 3    import com.agical.rmock.core.MethodHandle;
 4    import com.agical.rmock.core.ProxyFactory;
 5   
 6    /**
 7    * <em>(c) Agical AB 2005</em>
 8    * @author joakim.ohlrogge
 9    *
 10   
 11    */
 12    public class InterfaceMethodHandle implements MethodHandle {
 13   
 14    private final Class returnType;
 15    private final Class[] parameterTypes;
 16    private final String objectId;
 17    private final ProxyFactory proxyFactory;
 18    private final String method;
 19    private final DefaultValueProvider defaultValueProvider = new DefaultValueProvider();
 20   
 21    /**
 22    * @param returnValue
 23    * @param parameterTypes
 24    * @param returnType
 25    */
 26  2149 public InterfaceMethodHandle(String objectId, String method, Class[] parameterTypes, Class returnType, ProxyFactory proxyFactory) {
 27  2149 this.objectId = objectId;
 28  2149 this.method = method;
 29  2149 this.parameterTypes = parameterTypes;
 30  2149 this.returnType = returnType;
 31  2149 this.proxyFactory = proxyFactory;
 32    }
 33   
 34    /**
 35    * @see com.agical.rmock.core.MethodHandle#getReturnType()
 36    */
 37  641 public Class getReturnType() {
 38  641 return returnType;
 39    }
 40   
 41    /**
 42    * @see com.agical.rmock.core.MethodHandle#getParameterTypes()
 43    */
 44  1 public Class[] getParameterTypes() {
 45  1 return parameterTypes;
 46    }
 47   
 48    /**
 49    * @see com.agical.rmock.core.MethodHandle#invoke(java.lang.Object[])
 50    */
 51  661 public Object invoke(Object[] args) throws Exception {
 52  661 return defaultValueProvider.getDefaultValue( returnType );
 53    }
 54    }