Class EventCapturer
java.lang.Object
com.opencqrs.framework.persistence.EventCapturer
- All Implemented Interfaces:
EventPublisher
- Direct Known Subclasses:
CommandEventCapturer
In-memory implementation of
EventPublisher using CapturedEvents.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the list of events captured by thisEventPublisher.<E> voidPublishes the given event and its meta-data onto the given subject with preconditions.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.opencqrs.framework.persistence.EventPublisher
publish, publish
-
Constructor Details
-
EventCapturer
public EventCapturer()
-
-
Method Details
-
getEvents
Retrieves the list of events captured by thisEventPublisher.- Returns:
- the list of captured events
-
publish
public <E> void publish(String subject, E event, Map<String, ?> metaData, List<Precondition> preconditions) Description copied from interface:EventPublisherPublishes the given event and its meta-data onto the given subject with preconditions.- Specified by:
publishin interfaceEventPublisher- Type Parameters:
E- the generic event type- Parameters:
subject- the absolute subject pathevent- the event objectmetaData- the event meta-datapreconditions- the preconditions that must not be violated
-