@Test public void newFunctionWithInputReturnsFunkyFunctionWithInput() { FunctionFactory funkyFactory = new FunctionFactory(null); class Instantiated {} ClassFunctionWithInput<Instantiated> classFunction = funkyFactory.newFunctionWithInput(Instantiated.class); assertTrue(classFunction instanceof FunkyFunctionWithInput); }
public <T> ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments) { return new FunkyFunctionWithInput<T>(newFunction(applyingClass, constructorArguments), inputHolder); }
FunctionFactory { public <T> ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments) { return new FunkyFunctionWithInput<T>(newFunction(applyingClass, constructorArguments), inputHolder); } }
FunctionFactory { public <T> ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments) { return new FunkyFunctionWithInput<T>(newFunction(applyingClass, constructorArguments), inputHolder); } FunctionFactory(InputHolder inputHolder); }
FunctionFactory { public <T> ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments) { return new FunkyFunctionWithInput<T>(newFunction(applyingClass, constructorArguments), inputHolder); } FunctionFactory(InputHolder inputHolder); ClassFunction<T> newFunction(Class<T> applyingClass, Object... constructorArguments); ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments); InputHolder getInputHolder(); }
FunctionFactory { public <T> ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments) { return new FunkyFunctionWithInput<T>(newFunction(applyingClass, constructorArguments), inputHolder); } FunctionFactory(InputHolder inputHolder); ClassFunction<T> newFunction(Class<T> applyingClass, Object... constructorArguments); ClassFunctionWithInput<T> newFunctionWithInput(Class<T> applyingClass, Object... constructorArguments); InputHolder getInputHolder();  }