public void OnSubscribe(IDisposable d)
        {
            try {
                onSubscribeCall(d);
            } catch (Exception e)
            {
                actual.OnSubscribe(EmptyDisposable.Instance);
                actual.OnError(e);
                return;
            }

            actual.OnSubscribe(d);
        }
예제 #2
0
 public void OnSubscribe(IDisposable d)
 {
     if (OnSubscribeHelper.SetDisposable(ref this.d, d))
     {
         actual.OnSubscribe(d);
     }
 }
예제 #3
0
        public void Subscribe(ICompletableSubscriber s)
        {
            CompletableInnerDisposable cid = new CompletableInnerDisposable(s, this);

            s.OnSubscribe(cid);

            if (Add(cid))
            {
                if (cid.IsDisposed())
                {
                    Remove(cid);
                }
            }
            else
            {
                Exception e = error;
                if (e != null)
                {
                    s.OnError(e);
                }
                else
                {
                    s.OnComplete();
                }
            }
        }
예제 #4
0
        public void Subscribe(ICompletableSubscriber s)
        {
            var oo = new OtherObserver(s, source);

            s.OnSubscribe(oo);

            oo.SetResource(other.Subscribe(oo));
        }
예제 #5
0
        public void Subscribe(ICompletableSubscriber s)
        {
            var oo = new OtherSubscriber(s, source);

            s.OnSubscribe(oo);

            other.Subscribe(oo);
        }
예제 #6
0
        public void OnSubscribe(ISubscription s)
        {
            if (OnSubscribeHelper.SetSubscription(ref this.s, s))
            {
                cs.OnSubscribe(this);

                s.Request(long.MaxValue);
            }
        }
예제 #7
0
 public void OnSubscribe(IDisposable d)
 {
     cs.OnSubscribe(d);
 }
예제 #8
0
 public static void Complete(ICompletableSubscriber cs)
 {
     cs.OnSubscribe(Instance);
     cs.OnComplete();
 }
예제 #9
0
 public static void Error(ICompletableSubscriber cs, Exception e)
 {
     cs.OnSubscribe(Instance);
     cs.OnError(e);
 }
예제 #10
0
 public void OnSubscribe(IDisposable d)
 {
     actual.OnSubscribe(d);
 }