Catel.Services.IDispatcherServiceExtensions.InvokeIfRequired C# (CSharp) Method

InvokeIfRequired() public static method

Executes the specified action asynchronously with the specified arguments on the thread that the Dispatcher was created on if required. To check whether this is necessary, it will check whether the current thread has access to the dispatcher.
The is null.
public static InvokeIfRequired ( this dispatcherService, System.Action action ) : void
dispatcherService this The dispatcher service.
action System.Action The action.
return void
        public static void InvokeIfRequired(this IDispatcherService dispatcherService, Action action)
        {
            dispatcherService.Invoke(action, true);
        }

Same methods

IDispatcherServiceExtensions::InvokeIfRequired ( this dispatcherService, Delegate method ) : void