Package com.opencqrs.framework.command
Interface StateRebuildingHandler.FromObject<I,E>
- Type Parameters:
I
- the instance typeE
- the event type to be sourced
- All Superinterfaces:
StateRebuildingHandler<I,
E>
- Enclosing interface:
StateRebuildingHandler<I,
E>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public static non-sealed interface StateRebuildingHandler.FromObject<I,E>
extends StateRebuildingHandler<I,E>
FunctionalInterface
to be implemented, if only the Java event is needed to reconstruct the instance
state.-
Nested Class Summary
Nested classes/interfaces inherited from interface com.opencqrs.framework.command.StateRebuildingHandler
StateRebuildingHandler.FromObject<I,
E>, StateRebuildingHandler.FromObjectAndMetaData<I, E>, StateRebuildingHandler.FromObjectAndMetaDataAndSubject<I, E>, StateRebuildingHandler.FromObjectAndMetaDataAndSubjectAndRawEvent<I, E>, StateRebuildingHandler.FromObjectAndRawEvent<I, E> -
Method Summary
-
Method Details
-
on
Applies the given event to the given instance (state).- Parameters:
instance
- the instance to apply the event to, may benull
event
- the event to apply- Returns:
- an instance with the event applied, ideally an immutable copy of the original instance
-