Delen via


GraphTransactionScope Class

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Represents a highly optimized wrapper around System.Transactions.TransactionScope. This extensively uses thread local storage and is therefore thread-bound. GraphTransactionScope is meant to be called from a using() class, same as TransactionScope.

Inheritance Hierarchy

System.Object
  Microsoft.VisualStudio.GraphModel.GraphTransactionScope
    Microsoft.VisualStudio.GraphModel.UndoableGraphTransactionScope

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

Syntax

'Declaration
Public Class GraphTransactionScope _
    Implements IDisposable
public class GraphTransactionScope : IDisposable
public ref class GraphTransactionScope : IDisposable
type GraphTransactionScope =  
    class 
        interface IDisposable 
    end
public class GraphTransactionScope implements IDisposable

The GraphTransactionScope type exposes the following members.

Constructors

  Name Description
Public method GraphTransactionScope() Constructor. This associates this GraphTransactionScope with ones on outer scope blocks by using a TLS variable.
Public method GraphTransactionScope(String) Constructor. This associates this GraphTransactionScope with ones on outer scope blocks by using a TLS variable.
Public method GraphTransactionScope(Transaction) Constructor. This associates this GraphTransactionScope with ones on outer scope blocks by using a TLS variable.
Public method GraphTransactionScope(GraphTransactionScopeOptions) Constructor. This associates this GraphTransactionScope with ones on outer scope blocks by using a TLS variable.

Top

Properties

  Name Description
Public property ScopeProperties The property bag associated with this scope.

Top

Methods

  Name Description
Public method Complete Mark us as completed. Dispose will check this and if this wasn't called, the transaction will abort.
Public method Dispose() IDisposable.Dispose.
Protected method Dispose(Boolean) Dispose implementation
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

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.GraphModel Namespace