public class CustomInstantiationStrategy implements InstantiationStrategy {
public InstantiationState instantiate(Class<?> markedClass, Object parameter) throws InvocationTargetException,
InstantiationException, IllegalAccessException {
InstantiationStateCreator creator = new InstantiationStateCreator();
if (markedClass.equals(CustomInstantiationSteps.class)) {
return creator.didInstantiate(new CustomInstantiationSteps(new Date()));
}
return creator.didNotInstantiate();
}