mirror of
https://github.com/AlexMacocian/SystemExtensions.git
synced 2026-07-19 15:59:30 +00:00
Expose SemaphoreSlim.Acquire with CancellationToken
This commit is contained in:
@@ -8,4 +8,9 @@ public static class SemaphoreSlimExtensions
|
||||
{
|
||||
return await SemaphoreSlimContext.Create(semaphore);
|
||||
}
|
||||
|
||||
public static async Task<SemaphoreSlimContext> Acquire(this SemaphoreSlim semaphore, CancellationToken cancellationToken)
|
||||
{
|
||||
return await SemaphoreSlimContext.Create(semaphore, cancellationToken);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user