Package 

Interface ObjectsStateChange

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      public interface ObjectsStateChange.Listener

      Interface for receiving notifications about Objects synchronization state changes.

      Implement this interface and register it with an ObjectsStateEmitter to be notifiedwhen synchronization state transitions occur.

    • Method Summary

      Modifier and Type Method Description
      abstract ObjectsSubscription on(@NotNull() ObjectsStateEvent event, @NotNull() ObjectsStateChange.Listener listener) Subscribes to a specific Objects synchronization state event.
      abstract void off(@NotNull() ObjectsStateChange.Listener listener) Unsubscribes the specified listener from all synchronization state events.
      abstract void offAll() Unsubscribes all listeners from all synchronization state events.
      • Methods inherited from class java.lang.Object

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

      • on

        @NonBlocking() abstract ObjectsSubscription on(@NotNull() ObjectsStateEvent event, @NotNull() ObjectsStateChange.Listener listener)

        Subscribes to a specific Objects synchronization state event.

        This method registers the provided listener to be notified when the specifiedsynchronization state event occurs. The returned subscription can be used tounsubscribe later when the notifications are no longer needed.

        Parameters:
        event - the synchronization state event to subscribe to (SYNCING or SYNCED)
        listener - the listener that will be called when the event occurs
      • off

        @NonBlocking() abstract void off(@NotNull() ObjectsStateChange.Listener listener)

        Unsubscribes the specified listener from all synchronization state events.

        After calling this method, the provided listener will no longer receiveany synchronization state event notifications.

        Parameters:
        listener - the listener to unregister from all events
      • offAll

        @NonBlocking() abstract void offAll()

        Unsubscribes all listeners from all synchronization state events.

        After calling this method, no listeners will receive any synchronizationstate event notifications until new listeners are registered.