Interface EventCollection
-
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
BaseEventCollection
public interface EventCollection extends Serializable
EventCollection is responsible for efficient mechanism to keep events provided to it. It's usually a short lived object and thus should not use any persistent storage. It's up to concrete implementation how to react to different type of events:- add
- update
- remove
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidadd(InstanceView<?> event)Invoked when new instance is createdCollection<InstanceView<?>>getEvents()Returns all collected events.voidremove(InstanceView<?> item)Invoked when instance is removedvoidupdate(InstanceView<?> item)Invoked when instance is updated
-
-
-
Method Detail
-
add
void add(InstanceView<?> event)
Invoked when new instance is created- Parameters:
event- view of the instance in compact way
-
update
void update(InstanceView<?> item)
Invoked when instance is updated- Parameters:
event- view of the instance in compact way
-
remove
void remove(InstanceView<?> item)
Invoked when instance is removed- Parameters:
event- view of the instance in compact way
-
getEvents
Collection<InstanceView<?>> getEvents()
Returns all collected events.- Returns:
- events
-
-