PostSharp 6.8 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Threading Namespace / Dispatcher­Factory Class / Dispatcher­Factory Methods / Dispatcher­Factory.​Get­Dispatcher­For­Synchronization­Context Method

DispatcherFactory.GetDispatcherForSynchronizationContext Method

Gets an implementation of the IDispatcher interface for a given SynchronizationContext.

Namespace:  PostSharp.Patterns.Threading
Assembly:  PostSharp.Patterns.Threading (in PostSharp.Patterns.Threading.dll) Version: 6.8.6.0 (6.8.6.0)
Syntax
C#
public static IDispatcher GetDispatcherForSynchronizationContext(
	SynchronizationContext synchronizationContext
)

Parameters

synchronizationContext
Type: System.Threading.SynchronizationContext
A SynchronizationContext.

Return Value

Type: IDispatcher
An implementation of IDispatcher that dispatches using synchronizationContext.
See Also