QC_Counter.dox.h
namespace Qore {
namespace Thread {
class Counter {
public:
constructor(softint c = 0);
public:
copy();
public:
int dec();
public:
destructor();
public:
int getCount();
public:
int getWaiting();
public:
int inc();
public:
nothing waitForZero();
public:
int waitForZero(timeout timeout_ms);
};
}
}
Qore::Thread::Counter
Implements a class that can be used for blocking a thread until a counter reaches zero.
Definition: QC_Counter.dox.h:13
Qore::Thread::Counter::waitForZero
nothing waitForZero()
Blocks a thread until the counter reaches zero.
Qore::Thread::Counter::dec
int dec()
Atomically decrements the counter value.
Qore::Thread::Counter::waitForZero
int waitForZero(timeout timeout_ms)
Blocks a thread until the counter reaches zero.
Qore::Thread::Counter::getCount
int getCount()
Returns the current counter value.
Qore::Thread::Counter::getWaiting
int getWaiting()
Returns the number of threads currently blocked on this object.
Qore::Thread::Counter::inc
int inc()
Atomically increments the counter value.
Qore::Thread::Counter::constructor
constructor(softint c=0)
Creates the Counter object.
Qore::Thread::Counter::destructor
destructor()
Destroys the Counter object.
Qore::Thread::Counter::copy
copy()
Creates a new Counter object with the same count as the original.
Qore
main Qore-language namespace
Definition: Pseudo_QC_All.dox.h:3