DispatchQueue.DispatchBarrierAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
DispatchBarrierAsync(DispatchBlock) | |
DispatchBarrierAsync(Action) |
Submits a barrier block for asynchronous execution on a dispatch queue |
DispatchBarrierAsync(DispatchBlock)
public void DispatchBarrierAsync (CoreFoundation.DispatchBlock block);
member this.DispatchBarrierAsync : CoreFoundation.DispatchBlock -> unit
Parameters
- block
- DispatchBlock
Applies to
DispatchBarrierAsync(Action)
Submits a barrier block for asynchronous execution on a dispatch queue
public void DispatchBarrierAsync (Action action);
member this.DispatchBarrierAsync : Action -> unit
Parameters
- action
- Action
Code block to submit as a barrier.
Remarks
Submits a block to a dispatch queue like DispatchAsync(Action) does and marks that block as a barrier.
This is only relevant for concurrent queues.
The submitted code block will wait for all pending concurrent blocks to complete execution, then it will execute the code block to completion. During the time that the barrier executes, any other code blocks submitted are queued, and will be scheduled to run (possibly concurrently) after the barrier method completes.