コード例 #1
0
        public IAsyncEnumerator <TResult> GetAsyncEnumerator()
        {
            var en = new SwitchMapEnumerator(_source.GetAsyncEnumerator(), _mapper);

            en.MoveNext();
            return(en);
        }
コード例 #2
0
        public IAsyncEnumerator <TResult> GetAsyncEnumerator(CancellationToken cancellationToken)
        {
            var en = new SwitchMapEnumerator(_source.GetAsyncEnumerator(cancellationToken), _mapper, cancellationToken);

            en.MoveNext();
            return(en);
        }
コード例 #3
0
        public IAsyncEnumerator <TResult> GetAsyncEnumerator(CancellationToken cancellationToken)
        {
            var sourceCTS = CancellationTokenSource.CreateLinkedTokenSource(cancellationToken);
            var en        = new SwitchMapEnumerator(_source.GetAsyncEnumerator(sourceCTS.Token), _mapper, sourceCTS);

            en.MoveNext();
            return(en);
        }
コード例 #4
0
 public InnerHandler(IAsyncEnumerator <TResult> source, SwitchMapEnumerator parent)
 {
     _source = source;
     _parent = parent;
 }
コード例 #5
0
 public InnerHandler(IAsyncEnumerator <TResult> source, SwitchMapEnumerator parent, CancellationTokenSource cts)
 {
     _source = source;
     _parent = parent;
     _cts    = cts;
 }