Main Page   Namespace List   Class Hierarchy   Compound List   Namespace Members   Compound Members  

SynchronousExecutor Class Template Reference

#include <SynchronousExecutor.h>

Inheritance diagram for SynchronousExecutor:

Executor Cancelable Waitable NonCopyable List of all members.

Public Methods

 SynchronousExecutor ()
 Create a new SynchronousExecutor.

virtual ~SynchronousExecutor () throw ()
 Destroy a SynchronousExecutor.

virtual void execute (const RunnableHandle &task) throw (Synchronization_Exception)
void execute (Runnable *task) throw (Synchronization_Exception)
virtual void cancel () throw (Synchronization_Exception)
virtual bool isCanceled () throw (Synchronization_Exception)
virtual void wait () throw (Synchronization_Exception)
virtual bool wait (unsigned long) throw (Synchronization_Exception)

Detailed Description

template<class LockType>
class ZThread::SynchronousExecutor< LockType >

Author:
Eric Crahen <crahen@cse.buffalo.edu>
Date:
<2002-06-04T07:51:29-0400>
Version:
2.2.2
A SynchronousExecutor runs tasks in the current thread, but allows only one thread to do so at any given time.

See also:
Executor.


Member Function Documentation

virtual void cancel   throw (Synchronization_Exception) [inline, virtual]
 

See also:
Executor::cancel()

Implements Executor.

void execute Runnable   task throw (Synchronization_Exception) [inline]
 

Convience method

See also:
Executor::execute(const RunnableHandle&)

virtual void execute const RunnableHandle &    task throw (Synchronization_Exception) [inline, virtual]
 

Submit a light wieght task to an Executor. This will not block the calling thread very long. The submitted task will be executed at some later point by another thread.

Exceptions:
Cancellation_Exception  thrown if a task is submited when the executor has been canceled.
Synchronization_Exception  thrown is some other error occurs.
See also:
Executor::execute(RunnableHandle&)

Implements Executor.

virtual bool isCanceled   throw (Synchronization_Exception) [inline, virtual]
 

See also:
Executor::isCanceled()

Implements Cancelable.

virtual bool wait unsigned    long throw (Synchronization_Exception) [inline, virtual]
 

See also:
Executor::wait(unsigned long)

Implements Executor.

virtual void wait   throw (Synchronization_Exception) [inline, virtual]
 

See also:
Executor::wait()

Implements Executor.


The documentation for this class was generated from the following file:
Generated on Mon Jun 10 22:44:46 2002 for ZThread by doxygen1.2.15