try
{
ParallelOptions Options = new ParallelOptions();
Options.CancellationToken = base.DownloadCancellation.Token;
Parallel.ForEach(base.BlockingCollection1, Options, ActiveSeeder =>
{
//...
});
}
catch
{
if (base.DownloadCancellation.IsCancellationRequested)
return false;
}
Parallel.Foreach/For 是否调用 BlockingCollection1.Take 函数有或没有我放入 ParallelOptions 的 CancellationToken?
有机会知道吗?