27#ifndef NIDAS_CORE_SAMPLESOURCESUPPORT_H
28#define NIDAS_CORE_SAMPLESOURCESUPPORT_H
36namespace nidas {
namespace core {
142 void distribute(
const std::list<const Sample*>& samps)
throw();
A list of SampleClients.
Definition SampleClientList.h:41
virtual void removeAll()
Big cleanup.
Definition SampleClientList.cc:80
Pure virtual interface of a client of Samples.
Definition SampleClient.h:38
A source of samples.
Definition SampleSourceSupport.h:47
bool _keepStats
Definition SampleSourceSupport.h:188
bool getKeepStats() const
Definition SampleSourceSupport.h:159
void removeSampleClient(SampleClient *c)
Remove a SampleClient from this SampleSource This will also remove a SampleClient if it has been adde...
Definition SampleSourceSupport.cc:88
SampleSource * getRawSampleSource()
Several objects in NIDAS can be both a SampleSource of raw Samples and processed Samples.
Definition SampleSourceSupport.h:60
void removeSampleClientForTag(SampleClient *c, const SampleTag *)
Add a SampleClient to this SampleSource.
Definition SampleSourceSupport.cc:121
void distribute(const Sample *s)
Distribute a sample to my clients, calling the receive() method of each client, passing the const poi...
Definition SampleSourceSupport.cc:141
bool _raw
Definition SampleSourceSupport.h:186
SampleClientList _clients
Current clients of all samples.
Definition SampleSourceSupport.h:173
void addSampleClientForTag(SampleClient *c, const SampleTag *)
Add a SampleClient to this SampleSource.
Definition SampleSourceSupport.cc:101
void addSampleClient(SampleClient *c)
Add a SampleClient to this SampleSource.
Definition SampleSourceSupport.cc:80
SampleSource * getProcessedSampleSource()
Several objects in NIDAS can be both a SampleSource of raw Samples and processed Samples.
Definition SampleSourceSupport.h:66
virtual ~SampleSourceSupport()
Definition SampleSourceSupport.h:58
void setKeepStats(bool val)
Definition SampleSourceSupport.h:154
SampleTagIterator getSampleTagIterator() const
Definition SampleSourceSupport.cc:75
int getClientCount() const
How many SampleClients are currently in my list.
Definition SampleSourceSupport.cc:136
nidas::util::Mutex _clientMapLock
Definition SampleSourceSupport.h:182
void removeSampleTag(const SampleTag *tag)
Definition SampleSourceSupport.cc:67
const SampleStats & getSampleStats() const
Definition SampleSourceSupport.h:149
std::map< dsm_sample_id_t, SampleClientList > _clientsBySampleId
Current clients of specific samples.
Definition SampleSourceSupport.h:178
nidas::util::Mutex _tagsMutex
Definition SampleSourceSupport.h:166
void removeAllSampleClients()
Big cleanup.
Definition SampleSourceSupport.h:116
SampleSourceSupport & operator=(const SampleSourceSupport &x)
No assignment.
void addSampleTag(const SampleTag *tag)
Add a SampleTag to this SampleSource.
Definition SampleSourceSupport.cc:60
std::set< SampleClient * > _clientSet
Definition SampleSourceSupport.h:180
SampleSourceSupport(bool raw)
Definition SampleSourceSupport.cc:37
void flush()
This implementation of SampleSource::flush() does nothing.
Definition SampleSourceSupport.h:147
std::list< const SampleTag * > getSampleTags() const
What SampleTags am I a SampleSource for?
Definition SampleSourceSupport.cc:54
SampleStats _stats
Definition SampleSourceSupport.h:184
std::list< const SampleTag * > _sampleTags
Definition SampleSourceSupport.h:168
Pure virtual interface for a source of Samples.
Definition SampleSource.h:48
A source of samples.
Definition SampleStats.h:41
Class for iterating over the SampleTags of a Project, Site, DSMConfig, or a SampleSource.
Definition NidsIterators.h:218
Class describing a group of variables that are sampled and handled together.
Definition SampleTag.h:88
Interface to a data sample.
Definition Sample.h:190
A C++ wrapper for a POSIX mutex.
Definition ThreadSupport.h:161
void lock()
Lock the Mutex.
Definition ThreadSupport.h:216
void unlock()
Unlock the Mutex.
Definition ThreadSupport.h:230
Sample * getSample(sampleType type, unsigned int len)
A convienence method for getting a sample of an enumerated type from a pool.
Definition Sample.cc:70
Root namespace for the NCAR In-Situ Data Acquisition Software.
Definition A2DConverter.h:31