SpecializedSyncContext Structure

A structure that applies and reverts changes to the SynchronizationContext.

Namespace:  Microsoft.VisualStudio.Threading
Assembly:  Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)

Syntax

'Declaration
Public Structure SpecializedSyncContext _
    Implements IDisposable
public struct SpecializedSyncContext : IDisposable
public value class SpecializedSyncContext : IDisposable
[<Sealed>]
type SpecializedSyncContext =  
    struct 
        interface IDisposable 
    end
JScript supports the use of structures, but not the declaration of new ones.

The SpecializedSyncContext type exposes the following members.

Methods

  Name Description
Public methodStatic member Apply Applies the specified SynchronizationContext to the caller's context.
Public method Dispose Reverts the SynchronizationContext to its previous instance.
Public method Equals Indicates whether this instance and a specified object are equal. (Inherited from ValueType.)
Public method GetHashCode Returns the hash code for this instance. (Inherited from ValueType.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Public method ToString Returns the fully qualified type name of this instance. (Inherited from ValueType.)

Top

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

Microsoft.VisualStudio.Threading Namespace