Class AbstractStore<E extends Event,​D extends StoreDelegate<E>>

    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected D delegate  
    • Constructor Summary

      Constructors 
      Constructor Description
      AbstractStore()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method 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.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbstractStore

        public AbstractStore()
    • Method Detail

      • setDelegate

        public void setDelegate​(D delegate)
        Description copied from interface: Store
        Sets the delegate on the store.
        Specified by:
        setDelegate in interface Store<E extends Event,​D extends StoreDelegate<E>>
        Parameters:
        delegate - new store delegate
      • unsetDelegate

        public void unsetDelegate​(D delegate)
        Description copied from interface: Store
        Withdraws the delegate from the store.
        Specified by:
        unsetDelegate in interface Store<E extends Event,​D extends StoreDelegate<E>>
        Parameters:
        delegate - store delegate to withdraw
      • hasDelegate

        public boolean hasDelegate()
        Description copied from interface: Store
        Indicates whether the store has a delegate.
        Specified by:
        hasDelegate in interface Store<E extends Event,​D extends StoreDelegate<E>>
        Returns:
        true if delegate is set
      • notifyDelegate

        protected void notifyDelegate​(E event)
        Notifies the delegate with the specified event.
        Parameters:
        event - event to delegate
      • notifyDelegate

        protected void notifyDelegate​(java.util.List<E> events)
        Notifies the delegate with the specified list of events.
        Parameters:
        events - list of events to delegate