7[DebuggerDisplay(
"{DisplayString,nq}")]
8[DebuggerTypeProxy(typeof(TimerDebuggerTypeProxy))]
21 long num = _timer._startTicks - TimerQueue.s_tickCountToTimeMap.TickCount +
_timer.
_dueTime;
120 if (flowExecutionContext)
125 if (dueTime != uint.MaxValue)
131 internal bool Change(uint dueTime, uint period)
140 if (dueTime == uint.MaxValue)
198 if (notifyWhenNoCallbacksRunning is
WaitHandle)
214 if (notifyWhenNoCallbacksRunning ==
null)
224 Fire(isThreadPool:
true);
227 internal void Fire(
bool isThreadPool =
false)
257 if (notifyWhenNoCallbacksRunning is
WaitHandle waitHandle)
263 ((
Task)notifyWhenNoCallbacksRunning).TrySetResult();
274 if (executionContext ==
null)
278 else if (isThreadPool)
static readonly FrameworkEventSource Log
void SetCurrentStackTrace()
static string InvalidOperation_TimerAlreadyClosed
static string ObjectDisposed_Generic
static void RunInternal(ExecutionContext executionContext, ContextCallback callback, object state)
static ? ExecutionContext Capture()
static void RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, object state)
static Thread CurrentThread
static int GetCurrentProcessorId()
readonly TimerQueueTimer _timer
TimerDebuggerTypeProxy(Timer timer)
TimerDebuggerTypeProxy(TimerQueueTimer timer)
DateTime? EstimatedNextTimeUtc
readonly TimerQueueTimer _timer
TimerQueueTimer(TimerCallback timerCallback, object state, uint dueTime, uint period, bool flowExecutionContext)
bool Change(uint dueTime, uint period)
void CallCallback(bool isThreadPool)
readonly ExecutionContext _executionContext
object _notifyWhenNoCallbacksRunning
readonly TimerCallback _timerCallback
static readonly ContextCallback s_callCallbackInContext
readonly TimerQueue _associatedTimerQueue
void Fire(bool isThreadPool=false)
bool Close(WaitHandle toSignal)
void SignalNoCallbacksRunning()
static TimerQueue[] Instances
bool UpdateTimer(TimerQueueTimer timer, uint dueTime, uint period)
void DeleteTimer(TimerQueueTimer timer)
delegate void TimerCallback(object? state)
delegate void ContextCallback(object? state)
static ValueTask FromException(Exception exception)
static TimeSpan FromMilliseconds(double value)