|
WvStreams
|
Public Member Functions | |
| WvLockFile (WvStringParm _lockname) | |
| bool | isok () |
| Check to make sure no lock is established or that it's owned by us. | |
| bool | lock () |
| Creates the lockfile with the current pid. | |
| bool | unlock () |
| Removes the lockfile if present. | |
| pid_t | readpid () |
| Returns one of three things: -1 if the lockfile exists, but is inaccessible. | |
| WvLockFile (WvStringParm _lockname) | |
| bool | isok () |
| Check to make sure no lock is established or that it's owned by us. | |
| bool | lock () |
| Creates the lockfile with the current pid. | |
| bool | unlock () |
| Removes the lockfile if present. | |
| pid_t | readpid () |
| Returns one of three things: -1 if the lockfile exists, but is inaccessible. | |
Protected Attributes | |
| WvString | lockname |
Definition at line 14 of file debian/libwvstreams-dev/usr/include/wvstreams/wvlockfile.h.
| WvLockFile::WvLockFile | ( | WvStringParm | _lockname | ) |
Definition at line 13 of file wvlockfile.cc.
| bool WvLockFile::isok | ( | ) |
Check to make sure no lock is established or that it's owned by us.
Definition at line 20 of file wvlockfile.cc.
References readpid().
| bool WvLockFile::lock | ( | ) |
| bool WvLockFile::unlock | ( | ) |
Removes the lockfile if present.
If there's no lockfile after, returns true, otherwise false.
Definition at line 41 of file wvlockfile.cc.
| pid_t WvLockFile::readpid | ( | ) |
Returns one of three things: -1 if the lockfile exists, but is inaccessible.
0 if there is no lockfile, or the process is not running. >0 The pid of the known-running process that owns the lock.
Definition at line 52 of file wvlockfile.cc.
References lock().
| bool WvLockFile::lock | ( | ) |
Creates the lockfile with the current pid.
Returns success/failure.
| bool WvLockFile::unlock | ( | ) |
Removes the lockfile if present.
If there's no lockfile after, returns true, otherwise false.
| pid_t WvLockFile::readpid | ( | ) |
Returns one of three things: -1 if the lockfile exists, but is inaccessible.
0 if there is no lockfile, or the process is not running. >0 The pid of the known-running process that owns the lock.
|
protected |
Definition at line 40 of file debian/libwvstreams-dev/usr/include/wvstreams/wvlockfile.h.