|
Yate
|
#include <yatephone.h>
Public Member Functions | |
| DataSource (const char *format="slin") | |
| virtual void | destroyed () |
| virtual void * | getObject (const String &name) const |
| virtual bool | valid () const |
| unsigned long | Forward (const DataBlock &data, unsigned long tStamp=invalidStamp(), unsigned long flags=0) |
| bool | attach (DataConsumer *consumer, bool override=false) |
| bool | detach (DataConsumer *consumer) |
| void | clear () |
| DataTranslator * | getTranslator () const |
| void | synchronize (unsigned long tStamp) |
| unsigned long | nextStamp () const |
Protected Attributes | |
| unsigned long | m_nextStamp |
| ObjList | m_consumers |
Friends | |
| class | DataTranslator |
A data source
| DataSource | ( | const char * | format = "slin" | ) | [inline, explicit] |
Source constructor
| format | Name of the data format, default "slin" (Signed Linear) |
| bool attach | ( | DataConsumer * | consumer, |
| bool | override = false |
||
| ) |
Attach a data consumer
| consumer | Data consumer to attach |
| override | Attach as temporary source override |
| void clear | ( | ) |
Detach all data consumers
| virtual void destroyed | ( | ) | [virtual] |
Source's destruct notification - detaches all consumers
Reimplemented from RefObject.
Reimplemented in ThreadedSource.
| bool detach | ( | DataConsumer * | consumer | ) |
Detach a data consumer
| consumer | Data consumer to detach |
| unsigned long Forward | ( | const DataBlock & | data, |
| unsigned long | tStamp = invalidStamp(), |
||
| unsigned long | flags = 0 |
||
| ) |
Forwards the data to its consumers
| data | The raw data block to forward |
| tStamp | Timestamp of data - typically samples |
| flags | Indicator flags associated with the data block |
Get a pointer to a derived class given that class name
| name | Name of the class we are asking for |
Reimplemented from RefObject.
| DataTranslator* getTranslator | ( | ) | const [inline] |
Get the master translator object if this source is part of a translator
| unsigned long nextStamp | ( | ) | const [inline] |
Get the next expected position in the data stream
| void synchronize | ( | unsigned long | tStamp | ) |
Synchronize the source and attached consumers with another timestamp
| tStamp | New timestamp of data - typically samples |
| virtual bool valid | ( | ) | const [virtual] |
Check if this data source is still valid
Reimplemented from DataNode.
1.7.6.1