Public Methods | |
Construction | |
this (int maxSlots) | |
Creates an anonymous semaphore with the indicated number of slots. All slots are available. | |
this (int maxSlots, int availableSlots) | |
Creates an anonymous semaphore with the indicated number of slots. | |
this (char[] name, int maxSlots) | |
Creates a named semaphore with the indicated number of slots. All slots are available. | |
this (char[] name, int maxSlots, int availableSlots) | |
Creates a named semaphore with the indicated number of slots. | |
~this () | |
Calls the close() method, ensuring that the semaphore is released to the operating system when the object is destroyed. | |
Methods | |
void | Close () |
Closes the semaphore object handle. | |
boolean | Wait (uint timeout) |
Waits, for the specified period, for a slot on the semaphore to become available. | |
void | Wait () |
Waits forever for a slot on the semaphore to become available. | |
void | Release (uint cSlots) |
Releases the given number of slots acquired on the semaphore. | |
void | Release () |
Releases one slot acquired on the semaphore. | |
Properties | |
int | propget_NumSlots () |
The maximum number of slots in the semaphore. | |
int | propget_AvailableSlots () |
The number of available slots in the semaphore. | |
char[] | propget_Name () |
The name of the semaphore. | |
Public Attributes | |
Constants | |
const uint | INFINITE = (uint)0xFFFFFFFF |
Represents an infinite wait period. |
|
Calls the close() method, ensuring that the semaphore is released to the operating system when the object is destroyed.
|
|
Closes the semaphore object handle.
|
|
The number of available slots in the semaphore.
|
|
The name of the semaphore.
|
|
The maximum number of slots in the semaphore.
|
|
Releases one slot acquired on the semaphore.
|
|
Releases the given number of slots acquired on the semaphore.
|
|
Creates a named semaphore with the indicated number of slots.
|
|
Creates a named semaphore with the indicated number of slots. All slots are available.
|
|
Creates an anonymous semaphore with the indicated number of slots.
|
|
Creates an anonymous semaphore with the indicated number of slots. All slots are available.
|
|
Waits forever for a slot on the semaphore to become available.
|
|
Waits, for the specified period, for a slot on the semaphore to become available.
|
|
Represents an infinite wait period.
|
|
D Libraries documentation © Synesis Software Pty Ltd, 2002-2003 |