DispatcherQueueController DispatcherQueueController DispatcherQueueController DispatcherQueueController Class

Definition

Manages the lifetime of a DispatcherQueue. Provides methods to create and shutdown the DispatcherQueue.

public : sealed class DispatcherQueueController
struct winrt::Windows::System::DispatcherQueueController
public sealed class DispatcherQueueController
Public NotInheritable Class DispatcherQueueController
Attributes

Windows 10 requirements

Device family
Windows 10 Fall Creators Update (introduced v10.0.16299.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v5)

Remarks

Object and Thread Lifetime

DispatcherQueueController and its associated DispatcherQueue will be kept alive while the event loop is running. When Shutdown is completed, the loop is terminated and the dedicated thread will unwind. However, DispacherQueueController and the associated DispatcherQueue object can outlive thread’s lifetime and will be disposed when all their references are released.

Properties

DispatcherQueue DispatcherQueue DispatcherQueue DispatcherQueue

Gets the DispatcherQueue associated with this DispatcherQueueController.

Methods

CreateOnDedicatedThread() CreateOnDedicatedThread() CreateOnDedicatedThread() CreateOnDedicatedThread()

Creates a DispatcherQueue that you can use to run tasks on a dedicated thread.

ShutdownQueueAsync() ShutdownQueueAsync() ShutdownQueueAsync() ShutdownQueueAsync()

Stops the DispatcherQueue associated with this DispatcherQueueController. Shuts down the thread if the DispatcherQueueController was created by CreateOnDedicatedThread.