nidas v1.2.3
|
Interface of an output stream of samples. More...
#include <SampleOutput.h>
Public Member Functions | |
virtual | ~SampleOutput () |
virtual SampleOutput * | getOriginal () const =0 |
Get pointer to SampleOutput that was cloned. | |
virtual void | setName (const std::string &val)=0 |
virtual const std::string & | getName () const =0 |
virtual bool | isRaw () const =0 |
virtual void | addRequestedSampleTag (SampleTag *tag)=0 |
Some SampleOutputs don't send out all the Samples that they receive. | |
virtual std::list< const SampleTag * > | getRequestedSampleTags () const =0 |
virtual void | addSourceSampleTag (const SampleTag *tag)=0 |
Some SampleOutputs like to be informed of what SampleTags they will be receiving from their SampleSources before they make a connection. | |
virtual void | addSourceSampleTags (const std::list< const SampleTag * > &tags)=0 |
virtual std::list< const SampleTag * > | getSourceSampleTags () const =0 |
virtual void | requestConnection (SampleConnectionRequester *)=0 |
Request a connection, of this SampleOutput, but don't wait for it. | |
virtual int | getReconnectDelaySecs () const =0 |
Derived classes implement this to indicate whether a connection should be requested again if one fails. | |
virtual void | setReconnectDelaySecs (int val)=0 |
virtual int | getFd () const =0 |
virtual IOChannel * | getIOChannel () const =0 |
virtual size_t | write (const void *buf, size_t len)=0 |
Plain raw write, typically only used to write an initial header. | |
virtual void | close ()=0 |
virtual void | setHeaderSource (HeaderSource *val)=0 |
virtual void | setDSMConfig (const DSMConfig *val)=0 |
virtual const DSMConfig * | getDSMConfig () const =0 |
virtual void | setLatency (float val)=0 |
virtual float | getLatency () const =0 |
virtual bool | receive (const Sample *s)=0 |
Method called to pass a sample to this client. | |
virtual void | flush ()=0 |
Ask that this SampleClient send out any buffered Samples that it may be holding. | |
virtual IOChannelRequester * | connected (IOChannel *)=0 |
virtual void | fromDOMElement (const xercesc::DOMElement *)=0 |
Initialize myself from a xercesc::DOMElement. | |
virtual xercesc::DOMElement * | toDOMParent (xercesc::DOMElement *parent, bool complete) const |
Create a DOMElement and append it to the parent. | |
virtual xercesc::DOMElement * | toDOMElement (xercesc::DOMElement *node, bool complete) const |
Add my content into a DOMElement. | |
Static Public Member Functions | |
static const XMLCh * | getNamespaceURI () |
Protected Member Functions | |
virtual SampleOutput * | clone (IOChannel *iochannel)=0 |
Static Private Attributes | |
static XMLCh * | namespaceURI = 0 |
Interface of an output stream of samples.
|
inlinevirtual |
Some SampleOutputs don't send out all the Samples that they receive.
At configuration time, one can use this method to request the SampleTags that should be output from a SampleOutput. SampleOutput will own the pointer.
nidas::util::InvalidParameterException |
Implemented in nidas::dynld::raf::CVIOutput, and nidas::core::SampleOutputBase.
Some SampleOutputs like to be informed of what SampleTags they will be receiving from their SampleSources before they make a connection.
Users of SampleOutputs should call this method before calling requestConnection().
nidas::util::InvalidParameterException |
Implemented in nidas::core::SampleOutputBase.
|
pure virtual |
nidas::util::InvalidParameterException |
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::DSMEngine::connectOutputs(), nidas::core::SampleArchiver::connectSource(), nidas::dynld::raf::CVIProcessor::connectSource(), nidas::dynld::SampleProcessor::connectSource(), nidas::dynld::StatisticsProcessor::connectSource(), and nidas::dynld::raf::SyncRecordGenerator::connectSource().
|
protectedpure virtual |
nidas::util::IOException |
Implemented in nidas::core::SampleOutputBase, nidas::dynld::SampleOutputStream, and nidas::dynld::UDPSampleOutput.
Referenced by nidas::core::DSMEngine::closeOutputs(), nidas::dynld::raf::CVIProcessor::~CVIProcessor(), nidas::core::SampleArchiver::~SampleArchiver(), nidas::core::SampleIOProcessor::~SampleIOProcessor(), nidas::dynld::SampleProcessor::~SampleProcessor(), nidas::dynld::StatisticsProcessor::~StatisticsProcessor(), and nidas::dynld::raf::SyncRecordGenerator::~SyncRecordGenerator().
|
pure virtualinherited |
Implemented in nidas::dynld::XMLConfigAllService, nidas::dynld::XMLConfigService, nidas::core::SampleOutputBase, nidas::dynld::SampleOutputStream, nidas::dynld::UDPSampleOutput, and nidas::dynld::SampleInputStream.
Referenced by nidas::core::McSocketUDP::connected(), nidas::core::McSocket::connected(), nidas::core::FileSet::mounted(), and nidas::core::DatagramSocket::requestConnection().
Ask that this SampleClient send out any buffered Samples that it may be holding.
)
Implemented in DumpClient, SampleDispatcher, DataStats, DumpClient, nidas::core::DSMSensor, nidas::core::NearestResampler, nidas::core::NearestResamplerAtRate, nidas::core::RemoteSerialConnection, nidas::core::SampleAverager, nidas::core::SampleBuffer, nidas::core::SampleSorter, nidas::dynld::AsciiOutput, nidas::dynld::raf::CVIOutput, nidas::dynld::raf::CVIProcessor, nidas::dynld::raf::SyncRecordReader, nidas::dynld::raf::SyncRecordSource, nidas::dynld::SampleOutputStream, nidas::dynld::StatisticsCruncher, nidas::dynld::UDPSampleOutput, nidas::core::Resampler, and nidas::core::SampleThread.
Referenced by nidas::core::DSMEngine::closeOutputs(), nidas::core::SampleArchiver::flush(), nidas::dynld::raf::CVIProcessor::flush(), nidas::dynld::SampleProcessor::flush(), nidas::dynld::StatisticsProcessor::flush(), nidas::dynld::raf::CVIProcessor::~CVIProcessor(), nidas::core::SampleArchiver::~SampleArchiver(), nidas::core::SampleIOProcessor::~SampleIOProcessor(), nidas::dynld::SampleProcessor::~SampleProcessor(), nidas::dynld::StatisticsProcessor::~StatisticsProcessor(), and nidas::dynld::raf::SyncRecordGenerator::~SyncRecordGenerator().
|
pure virtualinherited |
Initialize myself from a xercesc::DOMElement.
nidas::util::InvalidParameterException |
Implemented in nidas::core::CharacterSensor, nidas::core::DatagramSocket, nidas::core::DSMCatalog, nidas::core::DSMConfig, nidas::core::DSMSensor, nidas::core::DSMServer, nidas::core::McSocket, nidas::core::McSocketUDP, nidas::core::MultipleUDPSockets, nidas::core::Project, nidas::core::SampleTag, nidas::core::SensorCatalog, nidas::core::ServiceCatalog, nidas::core::Site, nidas::core::Socket, nidas::core::ServerSocket, nidas::core::UnixIOChannel, nidas::core::Variable, nidas::core::VariableConverter, nidas::core::Linear, nidas::core::Polynomial, nidas::dynld::isff::CS_Krypton, nidas::dynld::raf::Arinc_IRS, nidas::dynld::raf::DSMArincSensor, nidas::dynld::raf::DSMMesaSensor, nidas::dynld::raf::IRIGSensor, nidas::core::CalFile, nidas::core::DSMService, nidas::core::FileSet, nidas::core::FsMount, nidas::core::SampleIOProcessor, nidas::core::SampleOutputBase, nidas::core::SerialSensor, nidas::dynld::isff::DAUSensor, nidas::dynld::isff::Wind2D, nidas::dynld::iss::TiltSensor, nidas::dynld::raf::CVIProcessor, nidas::dynld::raf::LamsSensor, nidas::dynld::RawSampleInputStream, nidas::dynld::RawSampleOutputStream, nidas::dynld::RawSampleService, nidas::dynld::SampleInputStream, and nidas::dynld::UDPSampleOutput.
Referenced by nidas::core::DSMConfig::fromDOMElement(), nidas::core::SampleIOProcessor::fromDOMElement(), and nidas::dynld::RawSampleOutputStream::fromDOMElement().
Implemented in nidas::core::SampleOutputBase.
Implemented in nidas::core::SampleOutputBase.
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::DSMConfig::findSampleOutputStreamFileSets(), and nidas::core::Project::findServerSampleOutputStreamFileSets().
Implemented in nidas::core::SampleOutputBase.
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::SampleOutputRequestThread::addConnectRequest(), nidas::core::DSMEngine::closeOutputs(), nidas::core::DSMEngine::connectOutputs(), nidas::core::SampleOutputRequestThread::run(), nidas::dynld::raf::CVIProcessor::~CVIProcessor(), nidas::core::SampleArchiver::~SampleArchiver(), nidas::core::SampleIOProcessor::~SampleIOProcessor(), nidas::dynld::SampleProcessor::~SampleProcessor(), nidas::dynld::StatisticsProcessor::~StatisticsProcessor(), and nidas::dynld::raf::SyncRecordGenerator::~SyncRecordGenerator().
References nidas::core::DOMable::namespaceURI.
Referenced by nidas::dynld::UDPSampleOutput::getProjectDOM(), nidas::core::Dataset::toDOMElement(), nidas::core::ProjectConfig::toDOMElement(), nidas::core::Dataset::toDOMParent(), nidas::core::Datasets::toDOMParent(), nidas::core::ProjectConfig::toDOMParent(), nidas::core::ProjectConfigs::toDOMParent(), nidas::core::DSMConfig::toDOMParent(), nidas::core::DSMSensor::toDOMParent(), nidas::core::Project::toDOMParent(), nidas::core::SampleTag::toDOMParent(), nidas::core::Site::toDOMParent(), nidas::core::ServerSocket::toDOMParent(), nidas::core::Variable::toDOMParent(), nidas::core::Datasets::writeXML(), and nidas::core::ProjectConfigs::writeXML().
|
pure virtual |
Get pointer to SampleOutput that was cloned.
Will be NULL if this SampleOutput is an un-cloned original.
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::DSMEngine::closeOutputs(), nidas::core::DSMEngine::disconnect(), nidas::core::SampleArchiver::disconnect(), nidas::dynld::raf::CVIProcessor::disconnect(), nidas::dynld::raf::SyncRecordGenerator::disconnect(), nidas::dynld::SampleProcessor::disconnect(), nidas::dynld::StatisticsProcessor::disconnect(), nidas::dynld::raf::CVIProcessor::~CVIProcessor(), nidas::core::SampleArchiver::~SampleArchiver(), nidas::dynld::SampleProcessor::~SampleProcessor(), nidas::dynld::StatisticsProcessor::~StatisticsProcessor(), and nidas::dynld::raf::SyncRecordGenerator::~SyncRecordGenerator().
Derived classes implement this to indicate whether a connection should be requested again if one fails.
@ return: -1 do not resubmit a connection request >=0 number of seconds to wait before submitting a request (0 means ASAP)
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::SampleOutputRequestThread::run().
|
pure virtual |
Implemented in nidas::core::SampleOutputBase.
|
pure virtual |
Implemented in nidas::core::SampleOutputBase.
Implemented in nidas::core::SampleOutputBase, and nidas::dynld::RawSampleOutputStream.
Referenced by nidas::core::DSMEngine::closeOutputs(), and nidas::core::DSMEngine::connectOutputs().
Method called to pass a sample to this client.
This method is typically called by a SampleSource for each of its SampleClients when it has a sample ready. Returns true: success false: sample rejected. This is meant to signal a warning-type situation - like a socket not being available temporarily. True errors will be thrown as an IOException.
)
Implemented in nidas::dynld::UDPSampleOutput, nidas::dynld::raf::SyncRecordSource, TestClient, nidas::core::DSMSensor, nidas::core::NearestResampler, nidas::core::NearestResamplerAtRate, nidas::core::RemoteSerialConnection, nidas::core::SampleAverager, nidas::core::SampleBuffer, nidas::core::SampleOutputBase, nidas::core::SampleSorter, nidas::dynld::raf::CVIProcessor, nidas::dynld::raf::SyncRecordReader, nidas::dynld::SampleOutputStream, nidas::dynld::StatisticsCruncher, DumpClient, SampleDispatcher, DataStats, DumpClient, nidas::dynld::AsciiOutput, and nidas::dynld::raf::CVIOutput.
|
pure virtual |
Request a connection, of this SampleOutput, but don't wait for it.
The SampleConnectionRequester will be notified via a call back to SampleConnectionRequester::connected(SampleOutput*,SampleOutput*) where the first SampleOutput points to the SampleOutput of the original request, and the second is often a new instance of a SampleOutput with a new IOChannel connection. Or the two pointers may point to the same SampleOutput.
nidas::util::IOException |
Implemented in nidas::core::SampleOutputBase, nidas::dynld::AsciiOutput, and nidas::dynld::raf::CVIOutput.
Referenced by StatsProcess::run(), and nidas::core::SampleOutputRequestThread::run().
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::DSMConfig::fromDOMElement().
|
pure virtual |
Implemented in nidas::core::SampleOutputBase.
nidas::util::InvalidParameterException |
Implemented in nidas::core::SampleOutputBase, and nidas::dynld::SampleOutputStream.
Implemented in nidas::core::SampleOutputBase.
Implemented in nidas::core::SampleOutputBase.
|
virtualinherited |
Add my content into a DOMElement.
xercesc::DOMException |
Reimplemented in nidas::core::DSMConfig, nidas::core::DSMSensor, nidas::core::Project, nidas::core::SampleTag, nidas::core::Site, nidas::core::ServerSocket, and nidas::core::Variable.
Referenced by nidas::core::ServerSocket::toDOMParent().
|
virtualinherited |
Create a DOMElement and append it to the parent.
xercesc::DOMException |
Reimplemented in nidas::core::DSMConfig, nidas::core::DSMSensor, nidas::core::Project, nidas::core::SampleTag, nidas::core::Site, nidas::core::ServerSocket, and nidas::core::Variable.
Plain raw write, typically only used to write an initial header.
nidas::util::IOException |
Implemented in nidas::core::SampleOutputBase.
Referenced by nidas::core::SampleInputHeader::write().
|
staticprivateinherited |
Referenced by nidas::core::DOMable::getNamespaceURI().