terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
TimerThread.cs
Go to the documentation of this file.
1using System;
7
8namespace System.Net
9{
10 // Token: 0x020001FF RID: 511
11 internal static class TimerThread
12 {
13 // Token: 0x06000C88 RID: 3208 RVA: 0x00028008 File Offset: 0x00026208
18
19 // Token: 0x06000C89 RID: 3209 RVA: 0x0002802C File Offset: 0x0002622C
21 {
22 if (!true)
23 {
24 }
25 if (!false)
26 {
27 }
28 throw new OutOfMemoryException();
29 }
30
31 // Token: 0x06000C8A RID: 3210 RVA: 0x00028050 File Offset: 0x00026250
33 {
34 if (!true)
35 {
36 }
37 throw new InvalidCastException();
38 }
39
40 // Token: 0x06000C8B RID: 3211 RVA: 0x000280DC File Offset: 0x000262DC
41 private static void Prod()
42 {
43 if (!true)
44 {
45 }
46 int num = 1;
47 long num2 = 0L;
48 bool flag;
49 if (Interlocked.CompareExchange(flag ? 1 : 0, num, (int)num2) != 0)
50 {
51 return;
52 }
53 }
54
55 // Token: 0x06000C8C RID: 3212 RVA: 0x00028100 File Offset: 0x00026300
56 private static void ThreadProc()
57 {
58 int num = 1;
60 int num2 = 1;
62 if (num == 0)
63 {
64 }
65 if (num == 0)
66 {
67 }
68 int num3 = 1;
69 int num4 = 1;
71 if (num == 0)
72 {
73 }
74 if (!false)
75 {
76 }
77 }
78
79 // Token: 0x06000C8D RID: 3213 RVA: 0x00028254 File Offset: 0x00026454
80 private static void StopTimerThread()
81 {
82 if (!true)
83 {
84 }
85 int num = 2;
86 int num2 = Interlocked.Exchange(int.MinValue, num);
87 }
88
89 // Token: 0x06000C8E RID: 3214 RVA: 0x00002050 File Offset: 0x00000250
90 private static bool IsTickBetween(int start, int end, int comparand)
91 {
92 throw new global::Cpp2IlInjected.AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
93 }
94
95 // Token: 0x06000C8F RID: 3215 RVA: 0x00028274 File Offset: 0x00026474
96 private static void OnDomainUnload(object sender, EventArgs e)
97 {
99 }
100
101 // Token: 0x04000ABA RID: 2746
102 private const int c_ThreadIdleTimeoutMilliseconds = 30000;
103
104 // Token: 0x04000ABB RID: 2747
105 private const int c_CacheScanPerIterations = 32;
106
107 // Token: 0x04000ABC RID: 2748
108 private const int c_TickCountResolution = 15;
109
110 // Token: 0x04000ABD RID: 2749
111 private static global::System.Collections.Generic.LinkedList<WeakReference> s_Queues;
112
113 // Token: 0x04000ABE RID: 2750
114 private static global::System.Collections.Generic.LinkedList<WeakReference> s_NewQueues;
115
116 // Token: 0x04000ABF RID: 2751
117 private static int s_ThreadState;
118
119 // Token: 0x04000AC0 RID: 2752
121
122 // Token: 0x04000AC1 RID: 2753
124
125 // Token: 0x04000AC2 RID: 2754
126 private static WaitHandle[] s_ThreadEvents;
127
128 // Token: 0x04000AC3 RID: 2755
129 private static int s_CacheScanIteration;
130
131 // Token: 0x04000AC4 RID: 2756
132 private static Hashtable s_QueuesCache;
133
134 // Token: 0x02000200 RID: 512
135 internal abstract class Queue
136 {
137 // Token: 0x06000C90 RID: 3216 RVA: 0x0002828C File Offset: 0x0002648C
142
143 // Token: 0x1700028E RID: 654
144 // (get) Token: 0x06000C91 RID: 3217 RVA: 0x000282A8 File Offset: 0x000264A8
145 internal int Duration
146 {
147 get
148 {
149 return this.m_DurationMilliseconds;
150 }
151 }
152
153 // Token: 0x06000C92 RID: 3218 RVA: 0x00002050 File Offset: 0x00000250
155 {
156 throw new global::Cpp2IlInjected.AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
157 }
158
159 // Token: 0x06000C93 RID: 3219
160 internal abstract TimerThread.Timer CreateTimer(TimerThread.Callback callback, object context);
161
162 // Token: 0x04000AC5 RID: 2757
164 }
165
166 // Token: 0x02000201 RID: 513
167 internal abstract class Timer : IDisposable
168 {
169 // Token: 0x06000C94 RID: 3220 RVA: 0x000282BC File Offset: 0x000264BC
176
177 // Token: 0x1700028F RID: 655
178 // (get) Token: 0x06000C95 RID: 3221 RVA: 0x000282E8 File Offset: 0x000264E8
179 internal int Duration
180 {
181 get
182 {
183 return this.m_DurationMilliseconds;
184 }
185 }
186
187 // Token: 0x17000290 RID: 656
188 // (get) Token: 0x06000C96 RID: 3222 RVA: 0x000282FC File Offset: 0x000264FC
189 internal int StartTime
190 {
191 get
192 {
193 return this.m_StartTimeMilliseconds;
194 }
195 }
196
197 // Token: 0x17000291 RID: 657
198 // (get) Token: 0x06000C97 RID: 3223 RVA: 0x00028310 File Offset: 0x00026510
199 internal int Expiration
200 {
201 get
202 {
203 /*
204An exception occurred when decompiling this method (06000C97)
205
206ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 System.Net.TimerThread/Timer::get_Expiration()
207
208 ---> System.Exception: Basic block has to end with unconditional control flow.
209{
210 Block_0:
211 stloc:int32(var_0_06, ldfld:int32(Timer::m_StartTimeMilliseconds, ldloc:Timer(this)))
212}
213
214 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
215 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
216 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
217 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
218 --- End of inner exception stack trace ---
219 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
220 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
221*/;
222 }
223 }
224
225 // Token: 0x17000292 RID: 658
226 // (get) Token: 0x06000C98 RID: 3224 RVA: 0x00028324 File Offset: 0x00026524
227 internal int TimeRemaining
228 {
229 get
230 {
231 /*
232An exception occurred when decompiling this method (06000C98)
233
234ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 System.Net.TimerThread/Timer::get_TimeRemaining()
235
236 ---> System.Exception: Basic block has to end with unconditional control flow.
237{
238 Block_0:
239 stloc:int32(var_1_08, ldfld:int32(Timer::m_DurationMilliseconds, ldloc:Timer(this)))
240 stloc:int32(var_3_10, callgetter:int32(Environment::get_TickCount))
241 stloc:int32(var_4_17, ldfld:int32(Timer::m_StartTimeMilliseconds, ldloc:Timer(this)))
242 stloc:int32(var_5_1F, ldfld:int32(Timer::m_StartTimeMilliseconds, ldloc:Timer(this)))
243}
244
245 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
246 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
247 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
248 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
249 --- End of inner exception stack trace ---
250 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
251 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
252*/;
253 }
254 }
255
256 // Token: 0x06000C99 RID: 3225
257 internal abstract bool Cancel();
258
259 // Token: 0x17000293 RID: 659
260 // (get) Token: 0x06000C9A RID: 3226
261 internal abstract bool HasExpired { get; }
262
263 // Token: 0x06000C9B RID: 3227 RVA: 0x00028354 File Offset: 0x00026554
264 public void Dispose()
265 {
266 }
267
268 // Token: 0x04000AC6 RID: 2758
270
271 // Token: 0x04000AC7 RID: 2759
273 }
274
275 // Token: 0x02000202 RID: 514
276 internal sealed class Callback : MulticastDelegate
277 {
278 // Token: 0x06000C9C RID: 3228 RVA: 0x00028364 File Offset: 0x00026564
279 public Callback(object @object, IntPtr method)
280 {
282 this.m_target = @object;
284 this.method_code = this;
285 }
286
287 // Token: 0x06000C9D RID: 3229 RVA: 0x000283C4 File Offset: 0x000265C4
288 public void Invoke(TimerThread.Timer timer, int timeNoticed, object context)
289 {
292 IntPtr method = this.method;
293 }
294
295 // Token: 0x06000C9E RID: 3230 RVA: 0x00002050 File Offset: 0x00000250
296 public IAsyncResult BeginInvoke(TimerThread.Timer timer, int timeNoticed, object context, AsyncCallback callback, object @object)
297 {
298 throw new global::Cpp2IlInjected.AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
299 }
300
301 // Token: 0x06000C9F RID: 3231 RVA: 0x000283E8 File Offset: 0x000265E8
302 public void EndInvoke(IAsyncResult result)
303 {
304 }
305 }
306
307 // Token: 0x02000203 RID: 515
308 private enum TimerThreadState
309 {
310 // Token: 0x04000AC9 RID: 2761
311 Idle,
312 // Token: 0x04000ACA RID: 2762
313 Running,
314 // Token: 0x04000ACB RID: 2763
315 Stopped
316 }
317
318 // Token: 0x02000204 RID: 516
320 {
321 // Token: 0x06000CA0 RID: 3232 RVA: 0x000283F8 File Offset: 0x000265F8
327
328 // Token: 0x06000CA1 RID: 3233 RVA: 0x0002841C File Offset: 0x0002661C
349
350 // Token: 0x06000CA2 RID: 3234 RVA: 0x000284AC File Offset: 0x000266AC
351 internal bool Fire([Out] int nextExpiration)
352 {
358 ((GCHandle)this.m_ThisHandle).Free();
359 long num = 0L;
360 int num2 = 6;
362 if (num == 0L)
363 {
364 if (num2 == 0)
365 {
366 return next2.Fire();
367 }
368 }
369 throw new OutOfMemoryException();
370 }
371
372 // Token: 0x04000ACC RID: 2764
374
375 // Token: 0x04000ACD RID: 2765
377 }
378
379 // Token: 0x02000205 RID: 517
381 {
382 // Token: 0x06000CA3 RID: 3235 RVA: 0x0002855C File Offset: 0x0002675C
384 {
385 }
386
387 // Token: 0x06000CA4 RID: 3236 RVA: 0x00028570 File Offset: 0x00026770
388 internal override TimerThread.Timer CreateTimer(TimerThread.Callback callback, object context)
389 {
390 /*
391An exception occurred when decompiling this method (06000CA4)
392
393ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Net.TimerThread/Timer System.Net.TimerThread/InfiniteTimerQueue::CreateTimer(System.Net.TimerThread/Callback,System.Object)
394
395 ---> System.Exception: Basic block has to end with unconditional control flow.
396{
397 Block_0:
398 stloc:int32(var_1_07, callgetter:int32(Environment::get_TickCount))
399}
400
401 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
402 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
403 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
404 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
405 --- End of inner exception stack trace ---
406 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
407 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
408*/;
409 }
410 }
411
412 // Token: 0x02000206 RID: 518
414 {
415 // Token: 0x06000CA5 RID: 3237 RVA: 0x00028584 File Offset: 0x00026784
416 internal TimerNode(TimerThread.Callback callback, object context, int durationMilliseconds, object queueLock)
417 {
421 if (callback != null)
422 {
423 this.m_Callback = callback;
424 }
425 }
426
427 // Token: 0x06000CA6 RID: 3238 RVA: 0x000285B8 File Offset: 0x000267B8
434
435 // Token: 0x17000294 RID: 660
436 // (get) Token: 0x06000CA7 RID: 3239 RVA: 0x000285E4 File Offset: 0x000267E4
437 internal override bool HasExpired
438 {
439 get
440 {
441 /*
442An exception occurred when decompiling this method (06000CA7)
443
444ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Boolean System.Net.TimerThread/TimerNode::get_HasExpired()
445
446 ---> System.Exception: Basic block has to end with unconditional control flow.
447{
448 Block_0:
449 stloc:TimerState(var_0_06, ldfld:TimerState(TimerNode::m_TimerState, ldloc:TimerNode(this)))
450}
451
452 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
453 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
454 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
455 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
456 --- End of inner exception stack trace ---
457 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
458 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
459*/;
460 }
461 }
462
463 // Token: 0x17000295 RID: 661
464 // (get) Token: 0x06000CA8 RID: 3240 RVA: 0x000285F8 File Offset: 0x000267F8
465 // (set) Token: 0x06000CA9 RID: 3241 RVA: 0x0002860C File Offset: 0x0002680C
467 {
468 get
469 {
470 return this.next;
471 }
472 set
473 {
475 }
476 }
477
478 // Token: 0x17000296 RID: 662
479 // (get) Token: 0x06000CAA RID: 3242 RVA: 0x00028620 File Offset: 0x00026820
480 // (set) Token: 0x06000CAB RID: 3243 RVA: 0x00028634 File Offset: 0x00026834
482 {
483 get
484 {
485 return this.prev;
486 }
487 set
488 {
490 }
491 }
492
493 // Token: 0x06000CAC RID: 3244 RVA: 0x00028648 File Offset: 0x00026848
494 internal override bool Cancel()
495 {
497 {
498 object queueLock = this.m_QueueLock;
500 long num = 0L;
502 {
503 }
509 if (timerNode != null)
510 {
512 }
513 if (num == 0L)
514 {
515 }
516 }
517 throw new OutOfMemoryException();
518 }
519
520 // Token: 0x06000CAD RID: 3245 RVA: 0x000286C4 File Offset: 0x000268C4
521 internal bool Fire()
522 {
524 {
525 }
529 object queueLock = this.m_QueueLock;
531 {
532 }
535 int num = 1;
537 long num2 = 0L;
540 int num3 = 5;
542 if (this.m_Callback != null)
543 {
545 }
546 if (num2 == 0L)
547 {
548 while (num3 != 0)
549 {
550 }
551 TimerThread.Callback callback = this.m_Callback;
552 object context = this.m_Context;
553 IntPtr method_code = callback.method_code;
554 IntPtr invoke_impl = callback.invoke_impl;
555 IntPtr method = callback.method;
556 }
557 throw new OutOfMemoryException();
558 }
559
560 // Token: 0x04000ACE RID: 2766
562
563 // Token: 0x04000ACF RID: 2767
565
566 // Token: 0x04000AD0 RID: 2768
567 private object m_Context;
568
569 // Token: 0x04000AD1 RID: 2769
570 private object m_QueueLock;
571
572 // Token: 0x04000AD2 RID: 2770
574
575 // Token: 0x04000AD3 RID: 2771
577
578 // Token: 0x02000207 RID: 519
579 private enum TimerState
580 {
581 // Token: 0x04000AD5 RID: 2773
582 Ready,
583 // Token: 0x04000AD6 RID: 2774
584 Fired,
585 // Token: 0x04000AD7 RID: 2775
586 Cancelled,
587 // Token: 0x04000AD8 RID: 2776
589 }
590 }
591
592 // Token: 0x02000208 RID: 520
594 {
595 // Token: 0x06000CAE RID: 3246 RVA: 0x000287A8 File Offset: 0x000269A8
601
602 // Token: 0x17000297 RID: 663
603 // (get) Token: 0x06000CAF RID: 3247 RVA: 0x000287CC File Offset: 0x000269CC
604 internal override bool HasExpired
605 {
606 get
607 {
608 }
609 }
610
611 // Token: 0x06000CB0 RID: 3248 RVA: 0x00002050 File Offset: 0x00000250
612 internal override bool Cancel()
613 {
614 throw new global::Cpp2IlInjected.AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
615 }
616
617 // Token: 0x04000AD9 RID: 2777
618 private int cancelled;
619 }
620 }
621}
class f__AnonymousType0<< Count > j__TPar
static AppDomain CurrentDomain
Definition AppDomain.cs:49
IntPtr method_code
Definition Delegate.cs:386
IntPtr invoke_impl
Definition Delegate.cs:371
static int TickCount
Callback(object @object, IntPtr method)
IAsyncResult BeginInvoke(TimerThread.Timer timer, int timeNoticed, object context, AsyncCallback callback, object @object)
void Invoke(TimerThread.Timer timer, int timeNoticed, object context)
void EndInvoke(IAsyncResult result)
override TimerThread.Timer CreateTimer(TimerThread.Callback callback, object context)
readonly int m_DurationMilliseconds
TimerThread.Timer CreateTimer(TimerThread.Callback callback, object context)
TimerThread.Timer CreateTimer()
Queue(int durationMilliseconds)
TimerThread.TimerNode next
TimerThread.TimerNode Prev
TimerThread.TimerNode prev
TimerThread.TimerNode Next
TimerThread.Callback m_Callback
TimerThread.TimerNode.TimerState m_TimerState
TimerNode(TimerThread.Callback callback, object context, int durationMilliseconds, object queueLock)
bool Fire([Out] int nextExpiration)
TimerQueue(int durationMilliseconds)
override TimerThread.Timer CreateTimer(TimerThread.Callback callback, object context)
readonly TimerThread.TimerNode m_Timers
readonly int m_StartTimeMilliseconds
Timer(int durationMilliseconds)
readonly int m_DurationMilliseconds
static TimerThread.Queue CreateQueue(int durationMilliseconds)
static void ThreadProc()
static int s_CacheScanIteration
static TimerThread.Queue GetOrCreateQueue(int durationMilliseconds)
static global::System.Collections.Generic.LinkedList< WeakReference > s_NewQueues
const int c_CacheScanPerIterations
static AutoResetEvent s_ThreadReadyEvent
static ManualResetEvent s_ThreadShutdownEvent
const int c_ThreadIdleTimeoutMilliseconds
static void StopTimerThread()
static void OnDomainUnload(object sender, EventArgs e)
static bool IsTickBetween(int start, int end, int comparand)
const int c_TickCountResolution
static global::System.Collections.Generic.LinkedList< WeakReference > s_Queues
static WaitHandle[] s_ThreadEvents
static Hashtable s_QueuesCache
static int Exchange(int location1, int value)
static int CompareExchange(int location1, int value, int comparand)
static void Exit(object obj)
Definition Monitor.cs:47
static void Enter(object obj)
Definition Monitor.cs:11
static Thread CurrentThread
Definition Thread.cs:381
static GCHandle Alloc(object value)
Definition GCHandle.cs:97