TransactionInterop.GetExportCookie(Transaction, Byte[]) 方法

定義

將異動物件轉換成匯出異動 Cookie。Transforms a transaction object into an export transaction cookie.

public:
 static cli::array <System::Byte> ^ GetExportCookie(System::Transactions::Transaction ^ transaction, cli::array <System::Byte> ^ whereabouts);
public:
 static cli::array <System::Byte> ^ GetExportCookie(System::Transactions::Transaction ^ transaction, cli::array <System::Byte> ^ exportCookie);
public static byte[] GetExportCookie (System.Transactions.Transaction transaction, byte[] whereabouts);
public static byte[] GetExportCookie (System.Transactions.Transaction transaction, byte[] exportCookie);
static member GetExportCookie : System.Transactions.Transaction * byte[] -> byte[]
static member GetExportCookie : System.Transactions.Transaction * byte[] -> byte[]
Public Shared Function GetExportCookie (transaction As Transaction, whereabouts As Byte()) As Byte()
Public Shared Function GetExportCookie (transaction As Transaction, exportCookie As Byte()) As Byte()

參數

transaction
Transaction

要封送處理的 Transaction 物件。The Transaction object to be marshaled.

whereaboutsexportCookie
Byte[]

描述目的地交易管理員位置的位址,An address that describes the location of the destination transaction manager. 其可允許兩個交易管理員彼此通訊,藉此將交易從一個系統傳播至另一個系統。This permits two transaction managers to communicate with one another and thereby propagate a transaction from one system to the other.

傳回

Byte[]

表示指定之 Transaction 物件的匯出異動 Cookie。An export transaction cookie representing the specified Transaction object.

備註

如果您想要匯出交易,請呼叫這個方法。Call this method if you want to export a transaction. 傳遞的會 transaction 封送處理到交易 cookie 中。The transaction that is passed along is marshaled into a transaction cookie. 然後,您可以將交易 cookie 傳送至目的地進程。You can then send the transaction cookie to the destination process. 這稱為在進程或系統之間傳播交易。This is referred to as propagating the transaction between processes or systems. 傳播會視為推播模型,其中本機交易會被推送至目的地。The propagation is considered to be a push model where the local transaction is pushed to the destination. 因此,所包含的資訊 whereabouts 必須描述目的地交易管理員。Therefore, information contained in whereabouts must describe the destination transaction manager.

如需不同傳播模型的詳細資訊,請參閱 TransactionInterop 類別的<備註>一節。For more information on different propagation models, see the Remarks section of the TransactionInterop class.

適用於