Click or drag to resize
ExtensionsInvokeIfRequired Method
Runs the provided action on the SynchronizationContext if one is provided otherwise runs the action on the current thread

Namespace: Particle
Assembly: Particle (in Particle.dll) Version: 0.8.5.14 (0.8.5.14)
Syntax
public static void InvokeIfRequired(
	this SynchronizationContext context,
	Action action
)

Parameters

context
Type: System.ThreadingSynchronizationContext
The SynchronizationContext.
action
Type: SystemAction
The action to run

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type SynchronizationContext. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also