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

ConcurrentExecutor Class Template Reference

#include <ConcurrentExecutor.h>

Inheritance diagram for ConcurrentExecutor:

Executor Cancelable Waitable NonCopyable List of all members.

Public Methods

 ConcurrentExecutor ()
 Create a new ConcurrentExecutor.

virtual ~ConcurrentExecutor () throw ()
 Destroy a new ConcurrentExecutor.

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

Detailed Description

template<class LockType, class FactoryType = DefaultThreadFactory, class QueueType = MonitoredQueue<RunnableHandle*, LockType>, typename RefType = CountedPtr<QueueType>>
class ZThread::ConcurrentExecutor< LockType, FactoryType, QueueType, RefType >

Author:
Eric Crahen <crahen@cse.buffalo.edu>
Date:
<2002-06-19T08:46:14-0400>
Version:
2.2.2
This is an Executor that will run submitted tasks in another thread. Only one thread is used per ConcurrentExecutor. The PoolExecutor will allow you to create an Executor that will service tasks with one or more threads.

See also:
Executor


Member Function Documentation

virtual void cancel   [inline, virtual]
 

See also:
Executor::cancel()

Implements Executor.

void execute Runnable   task [inline]
 

Convience method

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

Reimplemented from Executor.

virtual void execute const RunnableHandle &    task [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   [inline, virtual]
 

See also:
Executor::isCancel()

Implements Cancelable.

virtual bool wait unsigned long    timeout [inline, virtual]
 

See also:
Executor::wait(unsigned long)

Implements Executor.

virtual void wait   [inline, virtual]
 

See also:
Executor::wait()

Implements Executor.


The documentation for this class was generated from the following file:
Generated on Tue Aug 27 07:43:11 2002 for ZThread by doxygen1.2.17