PostSharp6.6//API Reference/Post­Sharp.​Patterns.​Threading Namespace/Dispatcher­Factory Class/Dispatcher­Factory Methods/Dispatcher­Factory.​Get­Dispatcher­For­Windows­Dispatcher Method

DispatcherFactory.GetDispatcherForWindowsDispatcher Method

Gets an implementation of the IDispatcher interface for a given instance of the System.Windows.Threading.Dispatcher class.

Namespace:  PostSharp.Patterns.Threading
Assembly:  PostSharp.Patterns.Threading (in PostSharp.Patterns.Threading.dll) Version: 6.6.10.0 (6.6.10.0)
Syntax
C#
public static IDispatcher GetDispatcherForWindowsDispatcher(
	Object dispatcher
)

Parameters

dispatcher
Type: System.Object
An instance of the System.Windows.Threading.Dispatcher class.

Return Value

Type: IDispatcher
An implementation of IDispatcher wrapping the functionality of dispatcher.
Remarks
Throws PlatformNotSupportedException on platforms that don't support WPF.
See Also