Udostępnij za pośrednictwem


MetadataStore.BeginTransaction Method

When overridden in a derived class, starts an explicit transaction on the metadata store that has the specified isolation level.

Namespace: Microsoft.Synchronization.MetadataStorage
Assembly: Microsoft.Synchronization.MetadataStorage (in microsoft.synchronization.metadatastorage.dll)

Syntax

'Declaration
Public MustOverride Sub BeginTransaction ( _
    isolationLevel As IsolationLevel _
)
'Usage
Dim instance As MetadataStore
Dim isolationLevel As IsolationLevel

instance.BeginTransaction(isolationLevel)
public abstract void BeginTransaction (
    IsolationLevel isolationLevel
)
public:
virtual void BeginTransaction (
    IsolationLevel isolationLevel
) abstract
public abstract void BeginTransaction (
    IsolationLevel isolationLevel
)
public abstract function BeginTransaction (
    isolationLevel : IsolationLevel
)

Parameters

  • isolationLevel
    The isolation level for the transaction.

Exceptions

Exception type Condition

InvalidOperationException

A metadata store has not been opened or created, or a transaction was already started.

Remarks

Changes that are saved after this method is called are not committed to the store until CommitTransaction is called.

An explicit transaction must be started before any changes can be written to the metadata store.

See Also

Reference

MetadataStore Class
MetadataStore Members
Microsoft.Synchronization.MetadataStorage Namespace