using System; using System.Diagnostics; using System.Runtime.InteropServices; using System.Threading.Tasks; using Cpp2IlInjected; namespace System.Threading { /// Represents a lightweight alternative to that limits the number of threads that can access a resource or pool of resources concurrently. // Token: 0x0200030C RID: 780 [Token(Token = "0x200030C")] [DebuggerDisplay("Current Count = {m_currentCount}")] [ComVisible(false)] public class SemaphoreSlim : IDisposable { /// Initializes a new instance of the class, specifying the initial and maximum number of requests that can be granted concurrently. /// The initial number of requests for the semaphore that can be granted concurrently. /// The maximum number of requests for the semaphore that can be granted concurrently. /// /// is less than 0, or is greater than , or is equal to or less than 0. // Token: 0x06001CDC RID: 7388 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CDC")] [Address(RVA = "0x2926E70", Offset = "0x2925C70", VA = "0x182926E70")] public SemaphoreSlim(int initialCount, int maxCount) { } /// Blocks the current thread until it can enter the . /// The current instance has already been disposed. // Token: 0x06001CDD RID: 7389 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CDD")] [Address(RVA = "0x2926DB0", Offset = "0x2925BB0", VA = "0x182926DB0")] public void Wait() { } /// Blocks the current thread until it can enter the , using a 32-bit signed integer that specifies the timeout. /// The number of milliseconds to wait, (-1) to wait indefinitely, or zero to test the state of the wait handle and return immediately. /// /// if the current thread successfully entered the ; otherwise, . /// /// is a negative number other than -1, which represents an infinite timeout -or- timeout is greater than . /// The has been disposed. // Token: 0x06001CDE RID: 7390 RVA: 0x00012BB8 File Offset: 0x00010DB8 [Token(Token = "0x6001CDE")] [Address(RVA = "0x2926890", Offset = "0x2925690", VA = "0x182926890")] public bool Wait(int millisecondsTimeout) { return default(bool); } /// Blocks the current thread until it can enter the , using a 32-bit signed integer that specifies the timeout, while observing a . /// The number of milliseconds to wait, (-1) to wait indefinitely, or zero to test the state of the wait handle and return immediately. /// The to observe. /// /// if the current thread successfully entered the ; otherwise, . /// /// was canceled. /// /// is a negative number other than -1, which represents an infinite timeout -or- timeout is greater than . /// The instance has been disposed, or the that created has been disposed. // Token: 0x06001CDF RID: 7391 RVA: 0x00012BD0 File Offset: 0x00010DD0 [Token(Token = "0x6001CDF")] [Address(RVA = "0x29268A0", Offset = "0x29256A0", VA = "0x1829268A0")] public bool Wait(int millisecondsTimeout, CancellationToken cancellationToken) { return default(bool); } // Token: 0x06001CE0 RID: 7392 RVA: 0x00012BE8 File Offset: 0x00010DE8 [Token(Token = "0x6001CE0")] [Address(RVA = "0x29267E0", Offset = "0x29255E0", VA = "0x1829267E0")] private bool WaitUntilCountOrTimeout(int millisecondsTimeout, uint startTime, CancellationToken cancellationToken) { return default(bool); } /// Asynchronously waits to enter the . /// A task that will complete when the semaphore has been entered. /// The has been disposed. // Token: 0x06001CE1 RID: 7393 RVA: 0x00002082 File Offset: 0x00000282 [Token(Token = "0x6001CE1")] [Address(RVA = "0x29266C0", Offset = "0x29254C0", VA = "0x1829266C0")] public Task WaitAsync() { return null; } /// Asynchronously waits to enter the , using a 32-bit signed integer to measure the time interval, while observing a . /// The number of milliseconds to wait, (-1) to wait indefinitely, or zero to test the state of the wait handle and return immediately. /// The to observe. /// A task that will complete with a result of if the current thread successfully entered the , otherwise with a result of . /// /// is a number other than -1, which represents an infinite timeout -or- timeout is greater than . /// The current instance has already been disposed. /// /// was canceled. // Token: 0x06001CE2 RID: 7394 RVA: 0x00002082 File Offset: 0x00000282 [Token(Token = "0x6001CE2")] [Address(RVA = "0x2926240", Offset = "0x2925040", VA = "0x182926240")] public Task WaitAsync(int millisecondsTimeout, CancellationToken cancellationToken) { return null; } // Token: 0x06001CE3 RID: 7395 RVA: 0x00002082 File Offset: 0x00000282 [Token(Token = "0x6001CE3")] [Address(RVA = "0x2925C40", Offset = "0x2924A40", VA = "0x182925C40")] private SemaphoreSlim.TaskNode CreateAndAddAsyncWaiter() { return null; } // Token: 0x06001CE4 RID: 7396 RVA: 0x00012C00 File Offset: 0x00010E00 [Token(Token = "0x6001CE4")] [Address(RVA = "0x29261C0", Offset = "0x2924FC0", VA = "0x1829261C0")] private bool RemoveAsyncWaiter(SemaphoreSlim.TaskNode task) { return default(bool); } // Token: 0x06001CE5 RID: 7397 RVA: 0x00002082 File Offset: 0x00000282 [Token(Token = "0x6001CE5")] [Address(RVA = "0x29266D0", Offset = "0x29254D0", VA = "0x1829266D0")] private Task WaitUntilCountOrTimeoutAsync(SemaphoreSlim.TaskNode asyncWaiter, int millisecondsTimeout, CancellationToken cancellationToken) { return null; } /// Releases the object once. /// The previous count of the . /// The current instance has already been disposed. /// The has already reached its maximum size. // Token: 0x06001CE6 RID: 7398 RVA: 0x00012C18 File Offset: 0x00010E18 [Token(Token = "0x6001CE6")] [Address(RVA = "0x2925E20", Offset = "0x2924C20", VA = "0x182925E20")] public int Release() { return 0; } /// Releases the object a specified number of times. /// The number of times to exit the semaphore. /// The previous count of the . /// The current instance has already been disposed. /// /// is less than 1. /// The has already reached its maximum size. // Token: 0x06001CE7 RID: 7399 RVA: 0x00012C30 File Offset: 0x00010E30 [Token(Token = "0x6001CE7")] [Address(RVA = "0x2925E30", Offset = "0x2924C30", VA = "0x182925E30")] public int Release(int releaseCount) { return 0; } // Token: 0x06001CE8 RID: 7400 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CE8")] [Address(RVA = "0x2925E10", Offset = "0x2924C10", VA = "0x182925E10")] private static void QueueWaiterTask(SemaphoreSlim.TaskNode waiterTask) { } /// Releases all resources used by the current instance of the class. // Token: 0x06001CE9 RID: 7401 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CE9")] [Address(RVA = "0x2925D90", Offset = "0x2924B90", VA = "0x182925D90", Slot = "4")] public void Dispose() { } /// Releases the unmanaged resources used by the , and optionally releases the managed resources. /// /// to release both managed and unmanaged resources; to release only unmanaged resources. // Token: 0x06001CEA RID: 7402 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CEA")] [Address(RVA = "0x2925D10", Offset = "0x2924B10", VA = "0x182925D10", Slot = "5")] protected virtual void Dispose(bool disposing) { } // Token: 0x06001CEB RID: 7403 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CEB")] [Address(RVA = "0x2925A40", Offset = "0x2924840", VA = "0x182925A40")] private static void CancellationTokenCanceledEventHandler(object obj) { } // Token: 0x06001CEC RID: 7404 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CEC")] [Address(RVA = "0x2925BA0", Offset = "0x29249A0", VA = "0x182925BA0")] private void CheckDispose() { } // Token: 0x06001CED RID: 7405 RVA: 0x00002082 File Offset: 0x00000282 [Token(Token = "0x6001CED")] [Address(RVA = "0x2925E00", Offset = "0x2924C00", VA = "0x182925E00")] private static string GetResourceString(string str) { return null; } // Token: 0x04001089 RID: 4233 [global::Cpp2IlInjected.FieldOffset(Offset = "0x10")] [Token(Token = "0x4001089")] private int m_currentCount; // Token: 0x0400108A RID: 4234 [global::Cpp2IlInjected.FieldOffset(Offset = "0x14")] [Token(Token = "0x400108A")] private readonly int m_maxCount; // Token: 0x0400108B RID: 4235 [global::Cpp2IlInjected.FieldOffset(Offset = "0x18")] [Token(Token = "0x400108B")] private int m_waitCount; // Token: 0x0400108C RID: 4236 [global::Cpp2IlInjected.FieldOffset(Offset = "0x20")] [Token(Token = "0x400108C")] private object m_lockObj; // Token: 0x0400108D RID: 4237 [global::Cpp2IlInjected.FieldOffset(Offset = "0x28")] [Token(Token = "0x400108D")] private ManualResetEvent m_waitHandle; // Token: 0x0400108E RID: 4238 [global::Cpp2IlInjected.FieldOffset(Offset = "0x30")] [Token(Token = "0x400108E")] private SemaphoreSlim.TaskNode m_asyncHead; // Token: 0x0400108F RID: 4239 [global::Cpp2IlInjected.FieldOffset(Offset = "0x38")] [Token(Token = "0x400108F")] private SemaphoreSlim.TaskNode m_asyncTail; // Token: 0x04001090 RID: 4240 [Token(Token = "0x4001090")] private static readonly Task s_trueTask; // Token: 0x04001091 RID: 4241 [Token(Token = "0x4001091")] private const int NO_MAXIMUM = 2147483647; // Token: 0x04001092 RID: 4242 [Token(Token = "0x4001092")] private static Action s_cancellationTokenCanceledEventHandler; // Token: 0x0200030D RID: 781 [Token(Token = "0x200030D")] private sealed class TaskNode : Task, IThreadPoolWorkItem { // Token: 0x06001CEF RID: 7407 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CEF")] [Address(RVA = "0x2927FC0", Offset = "0x2926DC0", VA = "0x182927FC0")] internal TaskNode() { } // Token: 0x06001CF0 RID: 7408 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CF0")] [Address(RVA = "0x2927F80", Offset = "0x2926D80", VA = "0x182927F80", Slot = "4")] void IThreadPoolWorkItem.ExecuteWorkItem() { } // Token: 0x06001CF1 RID: 7409 RVA: 0x00002050 File Offset: 0x00000250 [Token(Token = "0x6001CF1")] [Address(RVA = "0x402080", Offset = "0x400E80", VA = "0x180402080", Slot = "5")] void IThreadPoolWorkItem.MarkAborted(ThreadAbortException tae) { } // Token: 0x04001093 RID: 4243 [global::Cpp2IlInjected.FieldOffset(Offset = "0x58")] [Token(Token = "0x4001093")] internal SemaphoreSlim.TaskNode Prev; // Token: 0x04001094 RID: 4244 [global::Cpp2IlInjected.FieldOffset(Offset = "0x60")] [Token(Token = "0x4001094")] internal SemaphoreSlim.TaskNode Next; } } }