1 write to CancellationState
System.Core (1)
System\Linq\ParallelEnumerable.cs (1)
385settings.CancellationState = new CancellationState(cancellationToken);
109 references to CancellationState
System.Core (109)
System\Linq\Parallel\QueryOperators\AssociativeAggregationOperator.cs (1)
208outputStream[i] = new AssociativeAggregationOperatorEnumerator<TKey>(inputStream[i], this, i, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\ExceptQueryOperator.cs (4)
66leftStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 67rightStream, outputRecipient, settings.CancellationState.MergedCancellationToken); 73leftStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 74rightStream, outputRecipient, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\GroupJoinQueryOperator.cs (4)
86ExchangeUtilities.HashRepartitionOrdered(leftStream, m_leftKeySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 87rightStream, outputRecipient, partitionCount, settings.CancellationState.MergedCancellationToken); 92ExchangeUtilities.HashRepartition(leftStream, m_leftKeySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 93rightStream, outputRecipient, partitionCount, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\IntersectQueryOperator.cs (4)
68leftPartitionedStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 69rightPartitionedStream, outputRecipient, settings.CancellationState.MergedCancellationToken); 75leftPartitionedStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 76rightPartitionedStream, outputRecipient, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\JoinQueryOperator.cs (4)
88ExchangeUtilities.HashRepartitionOrdered(leftStream, m_leftKeySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 89rightStream, outputRecipient, settings.CancellationState.MergedCancellationToken); 94ExchangeUtilities.HashRepartition(leftStream, m_leftKeySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 95rightStream, outputRecipient, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\UnionQueryOperator.cs (4)
73leftStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken); 76leftHashStream, rightStream, outputRecipient, partitionCount, settings.CancellationState.MergedCancellationToken); 82leftStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken); 85leftHashStream, rightStream, outputRecipient, partitionCount, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Binary\ZipQueryOperator.cs (2)
98settings.CancellationState, settings.QueryId); 108settings.CancellationState, settings.QueryId);
System\Linq\Parallel\QueryOperators\BinaryQueryOperator.cs (1)
114IEnumerable<TOutput> opSequential = m_op.AsSequentialQuery(m_settings.CancellationState.ExternalCancellationToken);
System\Linq\Parallel\QueryOperators\Inlined\InlinedAggregationOperator.cs (3)
82&& cancelEx.CancellationToken == SpecifiedQuerySettings.CancellationState.ExternalCancellationToken 83&& SpecifiedQuerySettings.CancellationState.ExternalCancellationToken.IsCancellationRequested) 139outputStream[i] = CreateEnumerator<TKey>(i, partitionCount, inputStream[i], null, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\QueryOpeningEnumerator.cs (2)
132m_querySettings.CancellationState.ExternalCancellationToken); 165CancellationState.ThrowWithStandardMessageIfCanceled(m_querySettings.CancellationState.ExternalCancellationToken);
System\Linq\Parallel\QueryOperators\QueryOperator.cs (11)
135IEnumerable<TOutput> opSequential = AsSequentialQuery(querySettings.CancellationState.ExternalCancellationToken); 136return ExceptionAggregator.WrapEnumerable(opSequential, querySettings.CancellationState).GetEnumerator(); 152if(querySettings.CancellationState.MergedCancellationToken.IsCancellationRequested) 154if (querySettings.CancellationState.ExternalCancellationToken.IsCancellationRequested) 155throw new OperationCanceledException(querySettings.CancellationState.ExternalCancellationToken); 165querySettings.CancellationState, 210IEnumerable<TOutput> opSequential = AsSequentialQuery(querySettings.CancellationState.ExternalCancellationToken); 211IEnumerable<TOutput> opSequentialWithCancelChecks = CancellableEnumerable.Wrap(opSequential, querySettings.CancellationState.ExternalCancellationToken); 212return ExceptionAggregator.WrapEnumerable(opSequentialWithCancelChecks, querySettings.CancellationState).ToArray(); 232OutputOrdered, querySettings.CancellationState, querySettings.QueryId); 286settings.CancellationState, settings.QueryId);
System\Linq\Parallel\QueryOperators\QuerySettings.cs (14)
118if (this.CancellationState.ExternalCancellationToken.CanBeCanceled && settings2.CancellationState.ExternalCancellationToken.CanBeCanceled) 135CancellationToken externalCancellationToken = (this.CancellationState.ExternalCancellationToken.CanBeCanceled) ? this.CancellationState.ExternalCancellationToken : settings2.CancellationState.ExternalCancellationToken; 154QuerySettings settings = new QuerySettings(TaskScheduler, DegreeOfParallelism, CancellationState.ExternalCancellationToken, ExecutionMode, MergeOptions); 157settings.CancellationState.InternalCancellationTokenSource = topLevelCancellationTokenSource; 160settings.CancellationState.MergedCancellationTokenSource = 161CancellationTokenSource.CreateLinkedTokenSource(settings.CancellationState.InternalCancellationTokenSource.Token, settings.CancellationState.ExternalCancellationToken); 164settings.CancellationState.TopLevelDisposedFlag = topLevelDisposedFlag; 166Contract.Assert(settings.CancellationState.InternalCancellationTokenSource != null); 167Contract.Assert(settings.CancellationState.MergedCancellationToken.CanBeCanceled); 168Contract.Assert(settings.CancellationState.TopLevelDisposedFlag != null);
System\Linq\Parallel\QueryOperators\Unary\AnyAllSearchOperator.cs (1)
119settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\ContainsSearchOperator.cs (1)
107settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\DefaultIfEmptyQueryOperator.cs (1)
76inputStream[i], m_defaultValue, i, partitionCount, sharedEmptyCount, sharedLatch, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\DistinctQueryOperator.cs (4)
65inputStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 66recipient, settings.CancellationState.MergedCancellationToken); 72inputStream, null, null, m_comparer, settings.CancellationState.MergedCancellationToken), 73recipient, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\ElementAtQueryOperator.cs (2)
94outputStream[i] = new ElementAtQueryOperatorEnumerator(intKeyStream[i], m_index, resultFoundFlag, settings.CancellationState.MergedCancellationToken); 134CancellationState cancelState = SpecifiedQuerySettings.CancellationState;
System\Linq\Parallel\QueryOperators\Unary\FirstQueryOperator.cs (1)
91settings.CancellationState.MergedCancellationToken, inputStream.KeyComparer, i);
System\Linq\Parallel\QueryOperators\Unary\ForAllOperator.cs (1)
96inputStream[i], m_elementAction, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\GroupByQueryOperator.cs (4)
81inputStream, m_keySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 83settings.CancellationState.MergedCancellationToken 90inputStream, m_keySelector, m_keyComparer, null, settings.CancellationState.MergedCancellationToken), 92settings.CancellationState.MergedCancellationToken
System\Linq\Parallel\QueryOperators\Unary\IndexedWhereQueryOperator.cs (1)
111outputStream[i] = new IndexedWhereQueryOperatorEnumerator(inputStreamInt[i], m_predicate, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\LastQueryOperator.cs (1)
89inputStream[i], m_predicate, operatorState, sharedBarrier, settings.CancellationState.MergedCancellationToken,
System\Linq\Parallel\QueryOperators\Unary\ReverseQueryOperator.cs (1)
69outputStream[i] = new ReverseQueryOperatorEnumerator<TKey>(inputStream[i], settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\SelectManyQueryOperator.cs (2)
159outputStream[i] = new SelectManyQueryOperatorEnumerator<TLeftKey>(inputStream[i], this, settings.CancellationState.MergedCancellationToken); 178outputStream[i] = new IndexedSelectManyQueryOperatorEnumerator(inputStream[i], this, settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\Unary\TakeOrSkipQueryOperator.cs (1)
121settings.CancellationState.MergedCancellationToken, inputStream.KeyComparer);
System\Linq\Parallel\QueryOperators\Unary\TakeOrSkipWhileQueryOperator.cs (1)
151settings.CancellationState.MergedCancellationToken, inputStream.KeyComparer);
System\Linq\Parallel\QueryOperators\Unary\WhereQueryOperator.cs (1)
62settings.CancellationState.MergedCancellationToken);
System\Linq\Parallel\QueryOperators\UnaryQueryOperator.cs (1)
120IEnumerable<TOutput> opSequential = m_op.AsSequentialQuery(m_settings.CancellationState.ExternalCancellationToken);
System\Linq\ParallelEnumerable.cs (31)
4435ExceptionAggregator.ThrowOCEorAggregateException(ex, settings.CancellationState); 4439DisposeEnumerator<TSource>(e2, settings.CancellationState); 4444DisposeEnumerator<TSource>(e1, settings.CancellationState); 5455IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5456IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5457return ExceptionAggregator.WrapEnumerable(childWithCancelChecks, settings.CancellationState) 5497IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5498IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5499return ExceptionAggregator.WrapEnumerable(childWithCancelChecks, settings.CancellationState) 5500.First(ExceptionAggregator.WrapFunc<TSource, bool>(predicate, settings.CancellationState)); 5539IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5540IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5542settings.CancellationState).FirstOrDefault(); 5584IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5585IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5587childWithCancelChecks, settings.CancellationState) 5588.FirstOrDefault(ExceptionAggregator.WrapFunc<TSource, bool>(predicate, settings.CancellationState)); 5633IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5634IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5635return ExceptionAggregator.WrapEnumerable(childWithCancelChecks, settings.CancellationState).Last(); 5675IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5676IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5678childWithCancelChecks, settings.CancellationState) 5679.Last(ExceptionAggregator.WrapFunc<TSource, bool>(predicate, settings.CancellationState)); 5717IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5718IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5719return ExceptionAggregator.WrapEnumerable(childWithCancelChecks, settings.CancellationState).LastOrDefault(); 5758IEnumerable<TSource> childAsSequential = queryOp.Child.AsSequentialQuery(settings.CancellationState.ExternalCancellationToken); 5759IEnumerable<TSource> childWithCancelChecks = CancellableEnumerable.Wrap(childAsSequential, settings.CancellationState.ExternalCancellationToken); 5761childWithCancelChecks, settings.CancellationState) 5762.LastOrDefault(ExceptionAggregator.WrapFunc<TSource, bool>(predicate, settings.CancellationState));