LocalTaskSemaphore.tryLock

Try to acquire a lock.

If a lock cannot be acquired immediately, returns false and leaves the semaphore in its previous state.

class LocalTaskSemaphore
@safe
bool
tryLock
()

Return Value

Type: bool

true is returned iff the number of available locks is greater than one.

Meta