Méthode | Description | |
---|---|---|
AddCount ( ) : void |
Attempts to add one to the current count. This method throws InvalidOperationException if the count is already at zero or if the new count would be greater than Int32.MaxValue.
|
|
AddCount ( int signalCount ) : void |
Attempts to add the specified value to the current count. This method throws InvalidOperationException if the count is already at zero or if the new count would be greater than Int32.MaxValue.
|
|
AsyncCountdownEvent ( int count ) : System |
Creates an async-compatible countdown event.
|
|
Signal ( ) : void |
Attempts to subtract one from the current count. This method throws InvalidOperationException if the count is already at zero or if the new count would be less than zero.
|
|
Signal ( int signalCount ) : void |
Attempts to subtract the specified value from the current count. This method throws InvalidOperationException if the count is already at zero or if the new count would be less than zero.
|
|
TryAddCount ( ) : bool |
Attempts to add one to the current count. This method returns
|
|
TryAddCount ( int signalCount ) : bool |
Attempts to add the specified value to the current count. This method returns
|
|
TrySignal ( ) : bool |
Attempts to subtract one from the current count. This method returns
|
|
TrySignal ( int signalCount ) : bool |
Attempts to subtract the specified value from the current count. This method returns
|
|
Wait ( ) : void |
Synchronously waits for this event to be set. This method may block the calling thread.
|
|
Wait ( |
Synchronously waits for this event to be set. This method may block the calling thread.
|
|
WaitAsync ( ) : Task |
Asynchronously waits for this event to be set.
|
Méthode | Description | |
---|---|---|
ModifyCount ( int signalCount ) : bool |
Attempts to modify the current count by the specified amount. This method returns
|
public AddCount ( int signalCount ) : void | ||
signalCount | int | The amount to change the current count. This must be greater than zero. |
Résultat | void |
public AsyncCountdownEvent ( int count ) : System | ||
count | int | The number of signals this event will need before it becomes set. Must be greater than zero. |
Résultat | System |
public Signal ( int signalCount ) : void | ||
signalCount | int | The amount to change the current count. This must be greater than zero. |
Résultat | void |
public TryAddCount ( int signalCount ) : bool | ||
signalCount | int | The amount to change the current count. This must be greater than zero. |
Résultat | bool |
public TrySignal ( int signalCount ) : bool | ||
signalCount | int | The amount to change the current count. This must be greater than zero. |
Résultat | bool |
public Wait ( |
||
cancellationToken | The cancellation token used to cancel the wait. If this token is already canceled, this method will first check whether the event is set. | |
Résultat | void |