C# Class WinRTXamlToolkit.Async.AsyncSemaphore

Limits the number of awaiters that can access a resource or pool of resources concurrently.
Afficher le fichier Open project: xyzzer/WinRTXamlToolkit Class Usage Examples

Méthodes publiques

Méthode Description
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.

Method Details

AsyncSemaphore() public méthode

Initializes a new instance of the AsyncSemaphore class, reserving some concurrent entries.
initialCount
public AsyncSemaphore ( int initialCount ) : System
initialCount int The initial count.
Résultat System

Release() public méthode

Exits the semaphore and returns the previous count.
public Release ( ) : void
Résultat void

WaitAsync() public méthode

Blocks the current awaiter until the semaphore receives a signal.
public WaitAsync ( ) : System.Threading.Tasks.Task
Résultat System.Threading.Tasks.Task