78 references to ManagedThreadId
mscorlib (18)
system\environment.cs (1)
1806
return Thread.CurrentThread.
ManagedThreadId
;
system\io\filesystemenumerable.cs (2)
93
threadId = Thread.CurrentThread.
ManagedThreadId
;
117
if (threadId == Thread.CurrentThread.
ManagedThreadId
&& state == 0)
system\threading\CancellationTokenRegistration.cs (1)
86
tokenSource.ThreadIDExecutingCallbacks != Thread.CurrentThread.
ManagedThreadId
) //the executingThreadID is not this threadID.
system\threading\CancellationTokenSource.cs (4)
666
int myIndex = Thread.CurrentThread.
ManagedThreadId
% s_nLists;
730
ThreadIDExecutingCallbacks = Thread.CurrentThread.
ManagedThreadId
;
804
ThreadIDExecutingCallbacks = Thread.CurrentThread.
ManagedThreadId
;
859
callback.CancellationTokenSource.ThreadIDExecutingCallbacks = Thread.CurrentThread.
ManagedThreadId
;
system\threading\SpinLock.cs (2)
520
int m_newOwner = Thread.CurrentThread.
ManagedThreadId
;
709
return ((m_owner & (~LOCK_ID_DISABLE_MASK)) == Thread.CurrentThread.
ManagedThreadId
);
system\threading\Tasks\ConcurrentExclusiveSchedulerPair.cs (7)
357
Contract.Assert(!m_threadProcessingMapping.ContainsKey(Thread.CurrentThread.
ManagedThreadId
),
359
m_threadProcessingMapping[Thread.CurrentThread.
ManagedThreadId
] = ProcessingMode.ProcessingExclusiveTask;
377
m_threadProcessingMapping.TryRemove(Thread.CurrentThread.
ManagedThreadId
, out currentMode);
406
Contract.Assert(!m_threadProcessingMapping.ContainsKey(Thread.CurrentThread.
ManagedThreadId
),
408
m_threadProcessingMapping[Thread.CurrentThread.
ManagedThreadId
] = ProcessingMode.ProcessingConcurrentTasks;
437
m_threadProcessingMapping.TryRemove(Thread.CurrentThread.
ManagedThreadId
, out currentMode);
591
if (m_pair.m_threadProcessingMapping.TryGetValue(Thread.CurrentThread.
ManagedThreadId
, out currentThreadMode) &&
system\threading\threadpool.cs (1)
876
public readonly Random random = new Random(Thread.CurrentThread.
ManagedThreadId
);
System (15)
compmod\system\diagnostics\TraceEventCache.cs (1)
106
return Thread.CurrentThread.
ManagedThreadId
;
net\System\Net\_TimerThread.cs (9)
306
GlobalLog.Assert(m_Timers.Prev.Next == m_Timers, "TimerThread#{0}::CreateTimer()|m_Tail corruption.", Thread.CurrentThread.
ManagedThreadId
.ToString());
530
GlobalLog.Assert(m_TimerState != TimerState.Sentinel, "TimerThread#{0}::Fire()|TimerQueue tried to Fire a Sentinel.", Thread.CurrentThread.
ManagedThreadId
.ToString());
638
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() Start");
703
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() Waiting for " + waitDuration + "ms");
708
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() Awoke, cause: Shutdown");
713
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() Awoke, cause: " + (waitResult == WaitHandle.WaitTimeout ? "Timeout" : "Prod"));
734
if (Logging.On) Logging.PrintError(Logging.Web, "TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString(NumberFormatInfo.InvariantInfo) + "::ThreadProc() - Exception:" + exception.ToString());
735
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() exception: " + exception);
751
GlobalLog.Print("TimerThread#" + Thread.CurrentThread.
ManagedThreadId
.ToString() + "::ThreadProc() Stop");
sys\system\threading\Barrier.cs (5)
352
if (m_actionCallerID != 0 && Thread.CurrentThread.
ManagedThreadId
== m_actionCallerID)
453
if (m_actionCallerID != 0 && Thread.CurrentThread.
ManagedThreadId
== m_actionCallerID)
648
if (m_actionCallerID != 0 && Thread.CurrentThread.
ManagedThreadId
== m_actionCallerID)
790
m_actionCallerID = Thread.CurrentThread.
ManagedThreadId
;
936
if (m_actionCallerID != 0 && Thread.CurrentThread.
ManagedThreadId
== m_actionCallerID)
System.Activities (7)
System\Activities\WorkflowApplication.cs (7)
314
return this.isInHandler && this.handlerThreadId == Thread.CurrentThread.
ManagedThreadId
;
985
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
2721
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
2772
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
4999
application.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
5132
instance.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
5267
instance.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
System.Core (6)
System\Diagnostics\Eventing\Reader\EventLogWatcher.cs (2)
116
if (this.callbackThreadId != Thread.CurrentThread.
ManagedThreadId
) {
202
this.callbackThreadId = Thread.CurrentThread.
ManagedThreadId
;
System\Linq\Enumerable.cs (2)
76
threadId = Thread.CurrentThread.
ManagedThreadId
;
91
if (threadId == Thread.CurrentThread.
ManagedThreadId
&& state == 0) {
System\Linq\Parallel\Channels\AsynchronousChannel.cs (2)
208
Thread.CurrentThread.
ManagedThreadId
);
222
Thread.CurrentThread.
ManagedThreadId
);
System.Data (4)
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (4)
2662
return _threadIdOwningParserLock == Thread.CurrentThread.
ManagedThreadId
;
2666
Debug.Assert(_threadIdOwningParserLock == -1 || _threadIdOwningParserLock == Thread.CurrentThread.
ManagedThreadId
, "Another thread already claims to own the parser lock");
2670
_threadIdOwningParserLock = Thread.CurrentThread.
ManagedThreadId
;
2672
else if (_threadIdOwningParserLock == Thread.CurrentThread.
ManagedThreadId
) {
System.IO.Log (2)
System\IO\Log\FileRecordSequence.cs (2)
479
if (this.tailPinnedThreadID == Thread.CurrentThread.
ManagedThreadId
)
499
this.tailPinnedThreadID = Thread.CurrentThread.
ManagedThreadId
;
System.ServiceModel (7)
System\ServiceModel\ComIntegration\ComPlusDiagnosticTraceRecords.cs (5)
199
System.Threading.Thread.CurrentThread.
ManagedThreadId
, SafeNativeMethods.GetCurrentThreadId());
233
instanceID, System.Threading.Thread.CurrentThread.
ManagedThreadId
, SafeNativeMethods.GetCurrentThreadId(), callerIdentity, guidContextTrsansactionID);
239
instanceID, System.Threading.Thread.CurrentThread.
ManagedThreadId
, SafeNativeMethods.GetCurrentThreadId(), callerIdentity);
251
instanceID, System.Threading.Thread.CurrentThread.
ManagedThreadId
, SafeNativeMethods.GetCurrentThreadId(), callerIdentity,
262
instanceID, System.Threading.Thread.CurrentThread.
ManagedThreadId
, SafeNativeMethods.GetCurrentThreadId(), callerIdentity,
System\ServiceModel\ComIntegration\ComPlusThreadInitializer.cs (2)
180
System.Threading.Thread.CurrentThread.
ManagedThreadId
.ToString(CultureInfo.InvariantCulture),
240
System.Threading.Thread.CurrentThread.
ManagedThreadId
.ToString(CultureInfo.InvariantCulture),
System.ServiceModel.Activities (7)
System\ServiceModel\Activities\Dispatcher\WorkflowServiceInstance.cs (7)
279
return this.isInHandler && this.handlerThreadId == Thread.CurrentThread.
ManagedThreadId
;
1245
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
1299
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
1345
thisPtr.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
1377
thisPtr.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
1419
this.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
1456
thisPtr.handlerThreadId = Thread.CurrentThread.
ManagedThreadId
;
System.ServiceModel.Internals (2)
System\Runtime\SynchronizedPool.cs (2)
213
int thisThreadID = Thread.CurrentThread.
ManagedThreadId
;
266
int thisThreadID = Thread.CurrentThread.
ManagedThreadId
;
System.Web (2)
Management\WebEvents.cs (1)
2144
_threadId = Thread.CurrentThread.
ManagedThreadId
;
Util\AppVerifier.cs (1)
744
ThreadId = Thread.CurrentThread.
ManagedThreadId
;
System.Windows.Forms (4)
winforms\Managed\System\WinForms\AxHost.cs (3)
3734
threadId = Thread.CurrentThread.
ManagedThreadId
;
3823
if (threadId == Thread.CurrentThread.
ManagedThreadId
) {
3942
if (connectionPoint.threadId == Thread.CurrentThread.
ManagedThreadId
) {
winforms\Managed\System\WinForms\Control.Ime.cs (1)
1366
Debug.WriteLineIf(CompModSwitches.ImeMode.Level >= TraceLevel.Info, "Inside get_InputLanguageTable(), Input Language = " + InputLanguage.CurrentInputLanguage.Culture.DisplayName + ", Thread = " + System.Threading.Thread.CurrentThread.
ManagedThreadId
);
System.Workflow.Runtime (2)
DebugEngine\BreakSafeBase.cs (1)
44
return Thread.CurrentThread.
ManagedThreadId
== this.controllerManagedThreadId;
DebugEngine\DebugControllerThread.cs (1)
203
return this.controllerThread.
ManagedThreadId
;
WindowsBase (2)
Shared\MS\Win32\HwndWrapper.cs (2)
69
_ownerThreadID = new SecurityCriticalDataForSet<int>(Thread.CurrentThread.
ManagedThreadId
);
245
if(Thread.CurrentThread.
ManagedThreadId
== _ownerThreadID.Value)