C# Класс WinRTXamlToolkit.Async.AsyncSemaphore

Limits the number of awaiters that can access a resource or pool of resources concurrently.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AsyncSemaphore ( int initialCount ) : System

Initializes a new instance of the AsyncSemaphore class, reserving some concurrent entries.

Release ( ) : void

Exits the semaphore and returns the previous count.

WaitAsync ( ) : System.Threading.Tasks.Task

Blocks the current awaiter until the semaphore receives a signal.

Описание методов

AsyncSemaphore() публичный Метод

Initializes a new instance of the AsyncSemaphore class, reserving some concurrent entries.
initialCount
public AsyncSemaphore ( int initialCount ) : System
initialCount int The initial count.
Результат System

Release() публичный Метод

Exits the semaphore and returns the previous count.
public Release ( ) : void
Результат void

WaitAsync() публичный Метод

Blocks the current awaiter until the semaphore receives a signal.
public WaitAsync ( ) : System.Threading.Tasks.Task
Результат System.Threading.Tasks.Task