This is the online documentation for PostSharp 5.0.
Download PDF or CHM. Go to v4.3 or v5.0

IDispatcher Interface

Defines the semantics of a facility that executes actions synchronously or asynchronously, possibly on a different thread.

Namespace:  PostSharp.Patterns.Threading
Assembly:  PostSharp.Patterns.Threading (in PostSharp.Patterns.Threading.dll) Version: 5.0.33.0 (5.0.33.0)
Syntax
C#
public interface IDispatcher

The IDispatcher type exposes the following members.

Properties
  NameDescription
Public propertyIsInvokeSupported
Determines whether the Invoke(SendOrPostCallback, Object) method is supported.
Public propertySynchronizationContext
Gets the SynchronizationContext associated with the current dispatcher.
Top
Methods
  NameDescription
Public methodBeginInvoke
Queues an action for asynchronous execution.
Public methodCheckAccess
Determines whether the current thread has access to the current dispatcher.
Public methodInvoke
Executes an action synchronously.
Top
Remarks

Use the DispatcherFactory class to get implementations of this interface. You can also create a custom implementation.

See Also