public class AbstractStore<E extends Event,D extends StoreDelegate<E>> extends java.lang.Object implements Store<E,D>
Constructor and Description |
---|
AbstractStore() |
Modifier and Type | Method and Description |
---|---|
boolean |
hasDelegate()
Indicates whether the store has a delegate.
|
protected void |
notifyDelegate(E event)
Notifies the delegate with the specified event.
|
protected void |
notifyDelegate(java.util.List<E> events)
Notifies the delegate with the specified list of events.
|
void |
setDelegate(D delegate)
Sets the delegate on the store.
|
void |
unsetDelegate(D delegate)
Withdraws the delegate from the store.
|
protected D extends StoreDelegate<E> delegate
public void setDelegate(D delegate)
Store
setDelegate
in interface Store<E extends Event,D extends StoreDelegate<E>>
delegate
- new store delegatepublic void unsetDelegate(D delegate)
Store
unsetDelegate
in interface Store<E extends Event,D extends StoreDelegate<E>>
delegate
- store delegate to withdrawpublic boolean hasDelegate()
Store
hasDelegate
in interface Store<E extends Event,D extends StoreDelegate<E>>
protected void notifyDelegate(E event)
event
- event to delegateprotected void notifyDelegate(java.util.List<E> events)
events
- list of events to delegate