mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-19 01:31:17 -10:00
Adding reference source for System.Data System.Data.DataSetExtensions System.Data.Entity System.Data.Entity.Design System.Data.Linq System.Data.SqlXml System.ServiceModel System.ServiceModel.Activation System.ServiceModel.Activities System.ServiceModel.Channels System.ServiceModel.Discovery System.ServiceModel.Internals System.ServiceModel.Routing System.ServiceModel.WasHosting System.ServiceModel.Web System.Web System.Web.ApplicationServices System.Web.DynamicData System.Web.Entity System.Web.Entity.Design System.Web.Extensions System.Web.Mobile System.Web.Routing System.Web.Services System.Xml System.Xml.Linq
58 lines
2.0 KiB
C#
58 lines
2.0 KiB
C#
//------------------------------------------------------------
|
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
//------------------------------------------------------------
|
|
namespace System.ServiceModel.Transactions
|
|
{
|
|
using System.Diagnostics.CodeAnalysis;
|
|
using System.Runtime;
|
|
using System.ServiceModel.Security;
|
|
using System.Transactions;
|
|
using Microsoft.Transactions.Wsat.Messaging;
|
|
|
|
class WsatTransactionInfo : TransactionInfo
|
|
{
|
|
WsatProxy wsatProxy;
|
|
CoordinationContext context;
|
|
RequestSecurityTokenResponse issuedToken;
|
|
|
|
public WsatTransactionInfo(WsatProxy wsatProxy,
|
|
CoordinationContext context,
|
|
RequestSecurityTokenResponse issuedToken)
|
|
{
|
|
this.wsatProxy = wsatProxy;
|
|
this.context = context;
|
|
this.issuedToken = issuedToken;
|
|
}
|
|
|
|
[SuppressMessage(FxCop.Category.Security, FxCop.Rule.AptcaMethodsShouldOnlyCallAptcaMethods, Justification = "The calls into CoordinationContext are safe.")]
|
|
public override Transaction UnmarshalTransaction()
|
|
{
|
|
Transaction tx;
|
|
|
|
if (WsatIncomingTransactionCache.Find(this.context.Identifier, out tx))
|
|
return tx;
|
|
|
|
tx = this.wsatProxy.UnmarshalTransaction(this);
|
|
|
|
// Cache extended information for subsequent marshal operations
|
|
WsatExtendedInformation info = new WsatExtendedInformation(context.Identifier, context.Expires);
|
|
info.TryCache(tx);
|
|
|
|
// Cache the unmarshalled transaction for subsequent unmarshal operations
|
|
WsatIncomingTransactionCache.Cache(this.context.Identifier, tx);
|
|
|
|
return tx;
|
|
}
|
|
|
|
public CoordinationContext Context
|
|
{
|
|
get { return this.context; }
|
|
}
|
|
|
|
public RequestSecurityTokenResponse IssuedToken
|
|
{
|
|
get { return this.issuedToken; }
|
|
}
|
|
}
|
|
}
|