Transaction.SetDistributedTransactionIdentifier メソッド

定義

MSDTC 以外のプロモーターによって生成される分散トランザクション識別子を設定します。

public:
 void SetDistributedTransactionIdentifier(System::Transactions::IPromotableSinglePhaseNotification ^ promotableNotification, Guid distributedTransactionIdentifier);
public void SetDistributedTransactionIdentifier(System.Transactions.IPromotableSinglePhaseNotification promotableNotification, Guid distributedTransactionIdentifier);
member this.SetDistributedTransactionIdentifier : System.Transactions.IPromotableSinglePhaseNotification * Guid -> unit
Public Sub SetDistributedTransactionIdentifier (promotableNotification As IPromotableSinglePhaseNotification, distributedTransactionIdentifier As Guid)

パラメーター

promotableNotification
IPromotableSinglePhaseNotification

参加者によって実装される IPromotableSinglePhaseNotification インターフェイス。

distributedTransactionIdentifier
Guid

分散トランザクション マネージャーによって使用されるトランザクションの識別子。

注釈

このメソッドは、 IPromotableSinglePhaseNotification.Promote メソッドの処理中にのみ正常に呼び出すことができます。 このメソッドが他の時点で呼び出されると、 TransactionException がスローされます。

promotableNotification パラメーターの指定した値は、Transaction.EnlistPromotableSinglePhase呼び出しに最初に指定されたものと同じオブジェクトである必要があります。 そうでない場合は、 InvalidOperationException がスローされます。

適用対象