|
BFLibC 0.1
C Library
|


Go to the source code of this file.
Macros | |
| #define | kBFLockTimedWaitCodeTimedOut 0xff |
Typedefs | |
| typedef void * | BFLock |
Functions | |
| bool | BFLockIsValid (BFLock *_lock) |
| int | BFLockCreate (BFLock *lock) |
| int | BFLockDestroy (BFLock *lock) |
| int | BFLockWait (BFLock *lock) |
| bool | BFLockIsWaiting (BFLock *l) |
| int | BFLockTimedWait (BFLock *l, BFTime t) |
| int | BFLockRelease (BFLock *lock) |
| int | BFLockLock (BFLock *lock) |
| int | BFLockUnlock (BFLock *lock) |
| #define kBFLockTimedWaitCodeTimedOut 0xff |
| typedef void* BFLock |
author: brando date: 10/25/23 Lock object
Capabilities: mutex, conditional wait
| int BFLockCreate | ( | BFLock * | lock | ) |
Caller owns
| int BFLockDestroy | ( | BFLock * | lock | ) |
Releases memory
| bool BFLockIsValid | ( | BFLock * | _lock | ) |
Validates BFLock object
| bool BFLockIsWaiting | ( | BFLock * | l | ) |
true if lock is being blocked by BFLockWait
| int BFLockLock | ( | BFLock * | lock | ) |
Activates a mutex lock
| int BFLockRelease | ( | BFLock * | lock | ) |
Releases BFLock waiting on BFLockWait
Waits for a specific amount of time before continuing
if elapsed time reaches t, kBFLockTimedWaitCodeTimedOut returns
t : seconds with nanosecond resolution. e.g. 1.0 is one second
| int BFLockUnlock | ( | BFLock * | lock | ) |
Unlocks a mutex lock
| int BFLockWait | ( | BFLock * | lock | ) |
Waits until BFLockRelease is called on object