Class Subscriptions.DeferredSubscription

  • All Implemented Interfaces:
    org.reactivestreams.Subscription
    Enclosing class:
    Subscriptions

    public static class Subscriptions.DeferredSubscription
    extends java.lang.Object
    implements org.reactivestreams.Subscription
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void cancel()  
      protected boolean isCancelled()  
      void request​(long n)  
      boolean set​(org.reactivestreams.Subscription newSubscription)
      Atomically sets the single subscription and requests the missed amount from it.
      • Methods inherited from class java.lang.Object

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

      • DeferredSubscription

        public DeferredSubscription()
    • Method Detail

      • isCancelled

        protected boolean isCancelled()
      • cancel

        public void cancel()
        Specified by:
        cancel in interface org.reactivestreams.Subscription
      • request

        public void request​(long n)
        Specified by:
        request in interface org.reactivestreams.Subscription
      • set

        public boolean set​(org.reactivestreams.Subscription newSubscription)
        Atomically sets the single subscription and requests the missed amount from it.
        Parameters:
        newSubscription - the subscription to set
        Returns:
        false if this arbiter is cancelled or there was a subscription already set