ParallelLoopResult ParallelLoopResult ParallelLoopResult ParallelLoopResult Struct

定義

提供 Parallel 迴圈的執行完成狀態。Provides completion status on the execution of a Parallel loop.

public value class ParallelLoopResult
public struct ParallelLoopResult
type ParallelLoopResult = struct
Public Structure ParallelLoopResult
繼承
ParallelLoopResultParallelLoopResultParallelLoopResultParallelLoopResult

備註

如果IsCompleted傳回 true, 則迴圈會執行至完成, 讓迴圈的所有反復專案都已經執行。If IsCompleted returns true, then the loop ran to completion, such that all iterations of the loop were executed. 如果IsCompleted傳回 false 並LowestBreakIteration傳回Stop null, 則會使用呼叫來提前結束迴圈。If IsCompleted returns false and LowestBreakIteration returns null, a call to Stop was used to end the loop prematurely. 如果IsCompleted傳回 false, LowestBreakIteration並傳回非 null 整數值, Break則用來提前結束迴圈。If IsCompleted returns false and LowestBreakIteration returns a non-null integral value, Break was used to end the loop prematurely.

屬性

IsCompleted IsCompleted IsCompleted IsCompleted

取得迴圈是否已徹底執行,即迴圈中的所有反覆項目都已執行,而且迴圈未收到任何不當結束的要求。Gets whether the loop ran to completion, such that all iterations of the loop were executed and the loop didn't receive a request to end prematurely.

LowestBreakIteration LowestBreakIteration LowestBreakIteration LowestBreakIteration

取得呼叫 Break() 之最低反覆項目的索引。Gets the index of the lowest iteration from which Break() was called.

適用於

執行緒安全性

ParallelLoopResult所有公用成員都是安全線程, 而且可以從多個執行緒同時呼叫。All public members of ParallelLoopResult are thread safe and may be called from multiple threads concurrently.

另請參閱