예제 #1
0
        internal void Resubscribe()
        {
            if (Interlocked.Increment(ref wip) == 1)
            {
                do
                {
                    if (DisposableHelper.IsTerminated(ref d))
                    {
                        return;
                    }

                    source.Subscribe(this);
                } while (Interlocked.Decrement(ref wip) != 0);
            }
        }
        public void OnComplete()
        {
            if (Interlocked.Increment(ref wip) == 1)
            {
                do
                {
                    if (DisposableHelper.IsTerminated(ref d))
                    {
                        return;
                    }

                    if (it.MoveNext())
                    {
                        ICompletable c = it.Current;

                        c.Subscribe(this);
                    }
                    else
                    {
                        actual.OnComplete();
                    }
                } while (Interlocked.Decrement(ref wip) != 0);
            }
        }
예제 #3
0
 internal bool IsDisposed()
 {
     return(DisposableHelper.IsTerminated(ref d));
 }
예제 #4
0
 public bool IsDisposed()
 {
     return(DisposableHelper.IsTerminated(ref d));
 }