Exemplo n.º 1
0
        public void OnError(Exception e)
        {
            BackpressureHelper.Produced(ref requested, produced);

            Signal <T> v = Signal <T> .CreateOnError(e);

            value = v;
            BackpressureHelper.ScalarPostComplete(ref requested, v, actual);
        }
        public void OnComplete()
        {
            if (done)
            {
                return;
            }

            BackpressureHelper.Produced(ref requested, produced);

            if (hasValue)
            {
                BackpressureHelper.ScalarPostComplete(ref requested, value, actual);
            }
            else
            {
                actual.OnComplete();
            }
        }
        public void OnError(Exception e)
        {
            T v;

            try
            {
                v = resumeValue(e);
            }
            catch (Exception ex)
            {
                actual.OnError(new AggregateException(e, ex));
                return;
            }

            BackpressureHelper.Produced(ref requested, produced);

            v = value;
            BackpressureHelper.ScalarPostComplete(ref requested, v, actual);
        }
Exemplo n.º 4
0
        public void OnError(Exception e)
        {
            if (done)
            {
                return;
            }

            R v;

            try
            {
                v = onErrorCall(e);
            }
            catch (Exception ex)
            {
                actual.OnError(new AggregateException(e, ex));
                return;
            }

            BackpressureHelper.Produced(ref requested, produced);

            last = v;
            BackpressureHelper.ScalarPostComplete(ref requested, v, actual);
        }
Exemplo n.º 5
0
        public void OnComplete()
        {
            BackpressureHelper.Produced(ref requested, produced);

            BackpressureHelper.ScalarPostComplete(ref requested, value, actual);
        }