5 instantiations of SemaphoreSlim
mscorlib (1)
system\io\stream.cs (1)
67return LazyInitializer.EnsureInitialized(ref _asyncActiveSemaphore, () => new SemaphoreSlim(1, 1));
System (3)
net\System\Net\WebSockets\WebSocketBase.cs (1)
115m_SendFrameThrottle = new SemaphoreSlim(1, 1);
sys\system\collections\concurrent\BlockingCollection.cs (2)
243m_freeNodes = new SemaphoreSlim(boundedCapacity - collectionCount); 247m_occupiedNodes = new SemaphoreSlim(collectionCount);
System.Data (1)
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (1)
222SemaphoreSlim semaphore = new SemaphoreSlim(1);
56 references to SemaphoreSlim
mscorlib (52)
system\io\bufferedstream.cs (7)
352SemaphoreSlim sem = _this.EnsureAsyncActiveSemaphoreInitialized(); 587SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized(); 688SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized(); 796SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized(); 1015SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized(); 1099SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized(); 1245SemaphoreSlim sem = base.EnsureAsyncActiveSemaphoreInitialized();
system\io\stream.cs (4)
61private SemaphoreSlim _asyncActiveSemaphore; 63internal SemaphoreSlim EnsureAsyncActiveSemaphoreInitialized() 325var semaphore = EnsureAsyncActiveSemaphoreInitialized(); 471var semaphore = EnsureAsyncActiveSemaphoreInitialized();
system\security\cryptography\cryptostream.cs (2)
351var sem = base.EnsureAsyncActiveSemaphoreInitialized(); 606var sem = base.EnsureAsyncActiveSemaphoreInitialized();
system\threading\SemaphoreSlim.cs (39)
35/// The <see cref="SemaphoreSlim"/> provides a lightweight semaphore class that doesn't 39/// All public and protected members of <see cref="SemaphoreSlim"/> are thread-safe and may be used 41/// must only be used when all other operations on the <see cref="SemaphoreSlim"/> have 107/// Gets the current count of the <see cref="SemaphoreSlim"/>. 109/// <value>The current count of the <see cref="SemaphoreSlim"/>.</value> 122/// the <see cref="SemaphoreSlim"/> itself, nor does it decrement the semaphore's 127/// cref="SemaphoreSlim"/> has been disposed.</exception> 156/// Initializes a new instance of the <see cref="SemaphoreSlim"/> class, specifying 169/// Initializes a new instance of the <see cref="SemaphoreSlim"/> class, specifying 203/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>. 214/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>, while observing a 230/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>, using a <see 236/// <returns>true if the current thread successfully entered the <see cref="SemaphoreSlim"/>; 256/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>, using a <see 265/// <returns>true if the current thread successfully entered the <see cref="SemaphoreSlim"/>; 286/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>, using a 32-bit 291/// <returns>true if the current thread successfully entered the <see cref="SemaphoreSlim"/>; 302/// Blocks the current thread until it can enter the <see cref="SemaphoreSlim"/>, 309/// <returns>true if the current thread successfully entered the <see cref="SemaphoreSlim"/>; otherwise, false.</returns> 479/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>. 488/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>, while observing a 504/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>, 512/// the <see cref="SemaphoreSlim"/>, otherwise with a result of false. 525/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>, using a <see 538/// the <see cref="SemaphoreSlim"/>, otherwise with a result of false. 553/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>, using a <see 562/// the <see cref="SemaphoreSlim"/>, otherwise with a result of false. 583/// Asynchronously waits to enter the <see cref="SemaphoreSlim"/>, 593/// the <see cref="SemaphoreSlim"/>, otherwise with a result of false. 738/// Exits the <see cref="SemaphoreSlim"/> once. 740/// <returns>The previous count of the <see cref="SemaphoreSlim"/>.</returns> 749/// Exits the <see cref="SemaphoreSlim"/> a specified number of times. 752/// <returns>The previous count of the <see cref="SemaphoreSlim"/>.</returns> 755/// <exception cref="T:System.Threading.SemaphoreFullException">The <see cref="SemaphoreSlim"/> has 843/// cref="SemaphoreSlim"/>. 846/// Unlike most of the members of <see cref="SemaphoreSlim"/>, <see cref="Dispose()"/> is not 862/// Unlike most of the members of <see cref="SemaphoreSlim"/>, <see cref="Dispose(Boolean)"/> is not 888SemaphoreSlim semaphore = obj as SemaphoreSlim;
System (3)
net\System\Net\WebSockets\WebSocketBase.cs (1)
43private readonly SemaphoreSlim m_SendFrameThrottle;
sys\system\collections\concurrent\BlockingCollection.cs (2)
61private SemaphoreSlim m_freeNodes; 62private SemaphoreSlim m_occupiedNodes;
System.Data (1)
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (1)
222SemaphoreSlim semaphore = new SemaphoreSlim(1);