public class MockUnclusteredEventStore extends Object implements EventStoreApi, Closeable
| Constructor and Description |
|---|
MockUnclusteredEventStore() |
| Modifier and Type | Method and Description |
|---|---|
void |
acknowledgeEvent(long eventId,
String user,
String reason) |
long |
addEvent(SystemEvent event) |
static void |
clear() |
void |
close() |
long |
countEvents() |
SystemEvent |
getEvent(long eventId) |
EventQuery |
getEvents(EventQuery query)
Executes the event query.
|
public static void clear()
public long addEvent(SystemEvent event) throws AttivioException
addEvent in interface EventStoreApiAttivioExceptionpublic SystemEvent getEvent(long eventId)
getEvent in interface EventStoreApipublic EventQuery getEvents(EventQuery query) throws AttivioException
EventStoreApiEventQuery.getMaxFetchSize() is > 0, multiple calls might be needed to get all the
events. In that case, getEvents() should be called until EventQuery.isDone() returns true. Note that
the last call might return an empty list. An exception is thrown if getEvents() is called after
EventQuery.isDone().
EventQuery eventQuery = new EventQuery();
eventQuery.setSubsystem(subsystem);
eventQuery.setStart(start);
eventQuery.setEnd(end);
eventQuery.setGetAlreadyAcknowledged(getAcknoledeged);
eventQuery.setMaxFetchSize(maxFetchSize);
while (!eventQuery.isDone()) {
eventQuery = eventStore().getEvents(eventQuery);
// Do something with eventQuery.getEventList()
}
getEvents in interface EventStoreApiquery - the caller must pass the EventQuery object returned from the previous callAttivioExceptionpublic void acknowledgeEvent(long eventId,
String user,
String reason)
throws AttivioException
acknowledgeEvent in interface EventStoreApiAttivioExceptionpublic long countEvents()
throws AttivioException
countEvents in interface EventStoreApiAttivioExceptionpublic void close()
close in interface Closeableclose in interface AutoCloseableCopyright © 2018 Attivio, Inc. All Rights Reserved.
PATENT NOTICE: Attivio, Inc. Software Related Patents. With respect to the Attivio software product(s) being used, the following patents apply: Querying Joined Data Within A Search Engine Index: United States Patent No.(s): 8,073,840. Ordered Processing of Groups of Messages: U.S. Patent No.(s) 8,495,656. Signal processing approach to sentiment analysis for entities in documents: U.S. Patent No.(s) 8,725,494. Other U.S. and International Patents Pending.