dynamic::api::stack Class Reference

Maintain a count of a stack. More...

#include <thread.hpp>

Inheritance diagram for dynamic::api::stack:

cg::not_copyable cg::not_assignable cg::not_copyable cg::not_assignable

List of all members.

Public Member Functions

void push ()
void shutdown ()
bool check_shutdown ()
bool wait_pop ()
void wait_empty ()
 stack ()
 Initialise an empty stack.
void shutdown ()
 Sets the state to shutting down and awakens all waiting threads.
bool check_shutdown ()
 Returns true if we are shutting down.
void push ()
 Adds an item.
bool wait_pop ()
 Removes an item from the stack, or waits until an item is added.
void wait_empty ()
 Waits until the stack is empty.


Detailed Description

Maintain a count of a stack.

This is used by message queues to maintain the size of the queue, or wait for objects to be added. The strange thing is that the implementation is completely different in Win32 and pthreads.

Definition at line 183 of file posix/thread.hpp.


Member Function Documentation

bool dynamic::api::stack::wait_pop (  )  [inline]

Removes an item from the stack, or waits until an item is added.

Returns false if we are shutting down

Definition at line 215 of file win32/thread.hpp.


The documentation for this class was generated from the following files:

Generated on Thu Dec 18 22:14:19 2008 for C++Script by  doxygen 1.5.7.1