ReflectionExecutionImpl extends AbstractExecution<T> { @Override public boolean invoke(T component, ClassMapper classMapper) throws IllegalAccessException, InvocationTargetException { if (method.getParameterCount() > 0 && getMissingArgumentStrategy() == SKIP_INVOCATION && Stream.of(method.getParameters()) .map(Parameter::getType) .map(classMapper::applyOrNull) .anyMatch(Objects::isNull)) { return false; } final Object[] args = Stream.of(method.getParameters()) .map(Parameter::getType) .map(classMapper::apply) .toArray(); injectorProxy.invoke(method, component, args); return true; } ReflectionExecutionImpl(
        final Class<T> component,
        final State state,
        final Set<Dependency> dependencies,
        final Method method,
        final InjectorProxy injectorProxy
    ); @Override String getName(); Method getMethod(); @Override boolean invoke(T component, ClassMapper classMapper); @Override String toString();  }
@Test void directMethodInvocation() throws InvocationTargetException, IllegalAccessException { final Foo foo = new Foo(0); method.invoke(foo); assertEquals(1, foo.value); }
@Test void invoke() throws InvocationTargetException, IllegalAccessException { final Foo foo = new Foo(0); final Execution.ClassMapper classMapper = new Execution.ClassMapper() { @Override public <T> T apply(Class<T> type) { return null; } }; assertTrue(instance.invoke(foo, classMapper)); assertEquals(1, foo.value); }