WorkerThreadPoolQueueGUIWorkItem Method |
Adds a work item to the Threadpool that is immediately being processed.
When the WorkItem is finished Event OnCompleted is raised on the calling synchronization context, so that no BeginInvoke is needed to update the main thread.
Namespace:
Jam.Shell
Assembly:
ShellBrowser.Core (in ShellBrowser.Core.dll) Version: 6.3.1
Syntax public void QueueGUIWorkItem(
WaitCallback waitCallBack,
Object taskData,
EventHandler<GUIWorkItemCompletedEventArgs> completedHandler,
SynchronizationContext synchronizationContext
)
Public Sub QueueGUIWorkItem (
waitCallBack As WaitCallback,
taskData As Object,
completedHandler As EventHandler(Of GUIWorkItemCompletedEventArgs),
synchronizationContext As SynchronizationContext
)
public:
void QueueGUIWorkItem(
WaitCallback^ waitCallBack,
Object^ taskData,
EventHandler<GUIWorkItemCompletedEventArgs^>^ completedHandler,
SynchronizationContext^ synchronizationContext
)
member QueueGUIWorkItem :
waitCallBack : WaitCallback *
taskData : Object *
completedHandler : EventHandler<GUIWorkItemCompletedEventArgs> *
synchronizationContext : SynchronizationContext -> unit
Parameters
- waitCallBack
- Type: System.ThreadingWaitCallback
The WaitCallback to be executed in a thread. - taskData
- Type: SystemObject
Can hold any object. Is passed to the WaitcallBack delegate and passed further to Result - completedHandler
- Type: SystemEventHandlerGUIWorkItemCompletedEventArgs
The completed handler. - synchronizationContext
- Type: System.ThreadingSynchronizationContext
The synchronization context the OnCompleted event is raised in.
See Also