Delen via


LinkedTransaction Class

Manages the opening and closing of a globally linked transaction and any in-memory store (IMS) transactions that are in the linked transaction.

This API is not CLS-compliant. 

Inheritance Hierarchy

System.Object
  System.MarshalByRefObject
    Microsoft.VisualStudio.Modeling.Shell.LinkedTransaction

Namespace:  Microsoft.VisualStudio.Modeling.Shell
Assembly:  Microsoft.VisualStudio.Modeling.Sdk.Shell.12.0 (in Microsoft.VisualStudio.Modeling.Sdk.Shell.12.0.dll)

Syntax

'Declaration
<CLSCompliantAttribute(False)> _
Public Class LinkedTransaction _
    Inherits MarshalByRefObject _
    Implements IDisposable
[CLSCompliantAttribute(false)]
public class LinkedTransaction : MarshalByRefObject, 
    IDisposable
[CLSCompliantAttribute(false)]
public ref class LinkedTransaction : public MarshalByRefObject, 
    IDisposable
[<CLSCompliantAttribute(false)>]
type LinkedTransaction =  
    class 
        inherit MarshalByRefObject 
        interface IDisposable 
    end
public class LinkedTransaction extends MarshalByRefObject implements IDisposable

The LinkedTransaction type exposes the following members.

Constructors

  Name Description
Public method LinkedTransaction(String, IServiceProvider) Initializes a new instance of the LinkedTransaction class.
Public method LinkedTransaction(String, IServiceProvider, ModelingDocData) Initializes a new instance of the LinkedTransaction class.

Top

Properties

  Name Description
Public propertyStatic member GlobalUndoContext Gets the global undo context for the transaction.
Public property HasPendingChanges Gets the IMS transaction and verifies whether it contains changes that have not completed.
Public property IsActive Gets the IMS transaction and verifies whether it is currently active.
Public property Transaction Gets the IMS transaction.

Top

Methods

  Name Description
Public method Commit Commits the IMS transaction and the linked undo transaction.
Public method CreateObjRef Security Critical. Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from MarshalByRefObject.)
Public method Dispose Releases all resources used by the current instance of the LinkedTransaction class.
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Finalizes the transaction but does not dispose the transaction. (Overrides Object.Finalize().)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetLifetimeService Security Critical. Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from MarshalByRefObject.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Public method InitializeLifetimeService Security Critical. Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from MarshalByRefObject.)
Protected method MemberwiseClone() Creates a shallow copy of the current Object. (Inherited from Object.)
Protected method MemberwiseClone(Boolean) Creates a shallow copy of the current MarshalByRefObject object. (Inherited from MarshalByRefObject.)
Public method Rollback Undoes the IMS transaction and the linked undo transaction.
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

Top

Remarks

This class implements the IVsLinkedUndoTransactionManager interface.

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.Modeling.Shell Namespace