Main Page   Class Hierarchy   Compound List   Compound Members  

ArRangeDeviceThreaded Class Reference

A range device which can run in its own thread. More...

#include <ArRangeDeviceThreaded.h>

Inheritance diagram for ArRangeDeviceThreaded::

ArRangeDevice ArASyncTask ArThread ArSick List of all members.

Public Methods

 ArRangeDeviceThreaded (size_t currentBufferSize, size_t cumulativeBufferSize, const char *name, unsigned int maxRange)
 Constructor.

virtual ~ArRangeDeviceThreaded (void)
 Destructor.

virtual void * runThread (void *arg)=0
 The main run loop. More...

void run (void)
 Runs the device in this thread. More...

void runAsync (void)
 Runs the device in its own thread. More...

virtual int lockDevice (void)
 Lock this device. More...

virtual int tryLockDevice (void)
 Try to lock this device. More...

virtual int unlockDevice (void)
 Unlock this device. More...


Detailed Description

A range device which can run in its own thread.


Member Function Documentation

virtual int ArRangeDeviceThreaded::lockDevice void    [inline, virtual]
 

Lock this device.

If you are also inheriting an ASyncTask you MUST override this to use the lock from the ArASyncTask

Reimplemented from ArRangeDevice.

void ArRangeDeviceThreaded::run void    [inline]
 

Runs the device in this thread.

Runs the device in the calling thread.

See also:
ArThread::stopRunning

void ArRangeDeviceThreaded::runAsync void    [inline]
 

Runs the device in its own thread.

Runs the device in its own thread.

See also:
ArThread::stopRunning

virtual void* ArRangeDeviceThreaded::runThread void *    arg [pure virtual]
 

The main run loop.

Override this function and put your taskes run loop here. Check the value of getRunning() or myRunning periodicly in your loop. If the value goes false, the loop should exit and runThread() should return.

Reimplemented from ArASyncTask.

Reimplemented in ArSick.

virtual int ArRangeDeviceThreaded::tryLockDevice void    [inline, virtual]
 

Try to lock this device.

If you are also inheriting an ASyncTask you MUST override this to use the lock from the ArASyncTask

Reimplemented from ArRangeDevice.

virtual int ArRangeDeviceThreaded::unlockDevice void    [inline, virtual]
 

Unlock this device.

If you are also inheriting an ASyncTask you MUST override this to use the lock from the ArASyncTask

Reimplemented from ArRangeDevice.


The documentation for this class was generated from the following files:
Generated on Tue Nov 12 17:44:01 2002 for Aria by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001