3 instantiations of ContextData
System.Transactions.Local (3)
System\Transactions\Transaction.cs (2)
1074
return s_contextDataTable.GetValue(contextKey, (env) => new
ContextData
(true));
1140
get => t_staticData ??= new
ContextData
(false);
System\Transactions\TransactionScope.cs (1)
1074
_savedTLSContextData ??= new
ContextData
(false);
29 references to ContextData
System.Transactions.Local (29)
System\Transactions\Transaction.cs (13)
81
internal static Transaction? FastGetTransaction(TransactionScope? currentScope,
ContextData
contextData, out Transaction? contextTransaction)
143
ContextData
contextData =
ContextData
.LookupContextData(defaultLookup);
191
if (InteropMode(
ContextData
.TLSCurrentData.CurrentScope) != EnterpriseServicesInteropOption.None)
202
ContextData
.TLSCurrentData.CurrentTransaction = value;
1065
private static readonly ConditionalWeakTable<ContextKey,
ContextData
> s_contextDataTable = new ConditionalWeakTable<ContextKey,
ContextData
>();
1071
public static
ContextData
CreateOrGetCurrentData(ContextKey contextKey)
1097
public static bool TryGetCurrentData([NotNullWhen(true)] out
ContextData
? currentData)
1130
private static
ContextData
? t_staticData;
1138
internal static
ContextData
TLSCurrentData
1158
internal static
ContextData
LookupContextData(TxLookup defaultLookup)
1160
ContextData
? currentData;
System\Transactions\TransactionScope.cs (16)
945
ContextData
.TLSCurrentData = null;
951
_threadContextData =
ContextData
.TLSCurrentData;
994
ContextData
.TLSCurrentData = null;
998
_threadContextData =
ContextData
.TLSCurrentData;
1015
ContextData
.TLSCurrentData = null;
1020
ContextData
.TLSCurrentData = _threadContextData;
1076
_savedTLSContextData.CurrentScope =
ContextData
.TLSCurrentData.CurrentScope;
1077
_savedTLSContextData.CurrentTransaction =
ContextData
.TLSCurrentData.CurrentTransaction;
1078
_savedTLSContextData.DefaultComContextState =
ContextData
.TLSCurrentData.DefaultComContextState;
1079
_savedTLSContextData.WeakDefaultComContext =
ContextData
.TLSCurrentData.WeakDefaultComContext;
1086
ContextData
.TLSCurrentData.CurrentScope = _savedTLSContextData.CurrentScope;
1087
ContextData
.TLSCurrentData.CurrentTransaction = _savedTLSContextData.CurrentTransaction;
1088
ContextData
.TLSCurrentData.DefaultComContextState = _savedTLSContextData.DefaultComContextState;
1089
ContextData
.TLSCurrentData.WeakDefaultComContext = _savedTLSContextData.WeakDefaultComContext;
1183
private
ContextData
? _threadContextData;
1185
private
ContextData
? _savedTLSContextData;