Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members

DataConsumer Class Reference

#include <yatephone.h>

Inheritance diagram for DataConsumer:

DataNode RefObject GenObject DataTranslator List of all members.

Public Member Functions

 DataConsumer (const char *format="slin")
virtual ~DataConsumer ()
virtual void * getObject (const String &name) const
virtual void Consume (const DataBlock &data, unsigned long tStamp)=0
DataSourcegetConnSource () const
DataSourcegetOverSource () const
virtual DataSourcegetTransSource () const

Protected Member Functions

virtual bool synchronize (DataSource *source)

Friends

class DataSource

Detailed Description

A data consumer


Constructor & Destructor Documentation

DataConsumer const char *  format = "slin"  )  [inline]
 

Consumer constructor

Parameters:
format Name of the data format, default "slin" (Signed Linear)

virtual ~DataConsumer  )  [virtual]
 

Consumer's destructor - complains loudly if still attached to a source


Member Function Documentation

virtual void Consume const DataBlock data,
unsigned long  tStamp
[pure virtual]
 

Consumes the data sent to it from a source

Parameters:
data The raw data block to process; an empty block ends data
tStamp Timestamp of data - typically samples

DataSource* getConnSource  )  const [inline]
 

Get the data source of this object if it's connected

Returns:
A pointer to the DataSource object or NULL

virtual void* getObject const String name  )  const [virtual]
 

Get a pointer to a derived class given that class name

Parameters:
name Name of the class we are asking for
Returns:
Pointer to the requested class or NULL if this object doesn't implement it

Reimplemented from GenObject.

Reimplemented in DataTranslator.

DataSource* getOverSource  )  const [inline]
 

Get the override data source of this object if it's connected

Returns:
A pointer to the DataSource object or NULL

virtual DataSource* getTransSource  )  const [inline, virtual]
 

Get the data source of a translator object

Returns:
A pointer to the DataSource object or NULL

Reimplemented in DataTranslator.

virtual bool synchronize DataSource source  )  [protected, virtual]
 

Synchronize the consumer with a source

Parameters:
source Data source to copy the timestamp from
Returns:
True if we could synchronize with the source

Reimplemented in DataTranslator.


The documentation for this class was generated from the following file:
Generated on Fri Jul 7 03:11:38 2006 for Yate by  doxygen 1.4.4