27 #ifndef NIDAS_DYNLD_RAF_SYNCSERVER_H
28 #define NIDAS_DYNLD_RAF_SYNCSERVER_H
38 namespace nidas {
namespace dynld {
namespace raf {
45 virtual void stop() = 0;
213 nidas::util::auto_ptr<nidas::util::SocketAddress>
_address;
241 #endif // NIDAS_DYNLD_RAF_SYNCSERVER_H
float _rawSorterLengthSecs
Definition: SyncServer.h:217
Interface for an object that requests connections SampleOutputs.
Definition: ConnectionRequester.h:42
void signalStop()
Definition: SyncServer.cc:171
float _sorterLengthSecs
Definition: SyncServer.h:215
void disconnect(SampleOutput *output)
Implementation of SampleConnectionRequester::disconnect().
Definition: SyncServer.cc:467
SyncServer & operator=(const SyncServer &)
Definition: SyncServer.h:56
A class for parsing, formatting and doing operations on time, based on Unix time conventions, where leap seconds are ignored, so that there are always 60 seconds in a minute, 3600 seconds in an hour and 86400 seconds in a day.
Definition: UTime.h:76
void setXMLFileName(const std::string &name)
Definition: SyncServer.h:121
void read(bool once=false)
Definition: SyncServer.cc:411
An interface for a socket address.
Definition: SocketAddress.h:36
A class for serializing Samples on an OutputStream.
Definition: SampleOutputStream.h:40
StopSignal * _stop_signal
Definition: SyncServer.h:221
void initProject()
Definition: SyncServer.cc:99
virtual void interrupt()
Interrupt this thread.
Definition: SyncServer.cc:150
Interface of an output stream of samples.
Definition: SampleOutput.h:47
long long dsm_time_t
Posix time in microseconds, the number of non-leap microseconds since 1970 Jan 1 00:00 UTC...
Definition: Sample.h:61
Definition: SyncServer.h:40
static const int DEFAULT_PORT
Definition: SyncServer.h:167
static const float RAW_SORTER_LENGTH_SECS
Definition: SyncServer.h:171
StopSignal & operator=(const StopSignal &)
void resetAddress(nidas::util::SocketAddress *addr)
Definition: SyncServer.h:127
virtual void start()
Start the thread running, meaning execute the run method in a separate thread.
Definition: Thread.cc:406
nidas::util::auto_ptr< nidas::util::SocketAddress > _address
Definition: SyncServer.h:213
Pure virtual interface of a client of Samples.
Definition: SampleClient.h:38
void getTimeWindow(nidas::util::UTime *start, nidas::util::UTime *end)
Definition: SyncServer.cc:364
nidas::core::Sample * _firstSample
Definition: SyncServer.h:223
void setSorterLengthSeconds(float sorter_secs)
Definition: SyncServer.h:98
void initSensors(SampleInputStream &sis)
Definition: SyncServer.cc:112
Definition: Exception.h:35
~SyncServer()
Definition: SyncServer.cc:75
std::string _xmlFileName
Definition: SyncServer.h:209
Definition: SyncRecordGenerator.h:37
SampleOutputStream * _outputStream
Definition: SyncServer.h:207
dsm_time_t _startTime
Definition: SyncServer.h:225
std::list< std::string > _dataFileNames
Definition: SyncServer.h:211
void setRawSorterLengthSeconds(float sorter_secs)
Definition: SyncServer.h:104
Interface to a data sample.
Definition: Sample.h:189
void handleSample(nidas::core::Sample *sample)
Definition: SyncServer.cc:392
dsm_time_t _startWindow
Definition: SyncServer.h:228
dsm_time_t _endWindow
Definition: SyncServer.h:229
std::string getXMLFileName()
Return the current XML filename setting.
Definition: SyncServer.h:115
Definition: IOException.h:37
void openStream()
Open the data file input stream and read the nidas header, but do not parse the project.
Definition: SyncServer.cc:254
int run()
This method implements the Runnable interface for Threads, but it can also be called synchronously wh...
Definition: SyncServer.cc:130
RawSampleInputStream * _inputStream
Definition: SyncServer.h:206
SyncServer()
Definition: SyncServer.cc:57
void setTimeWindow(nidas::util::UTime start, nidas::util::UTime end)
Definition: SyncServer.cc:379
void addSampleClient(SampleClient *client)
Specify a SampleClient instance to receive the sync samples instead of writing the sync samples to an...
Definition: SyncServer.h:137
void stop()
Definition: SyncServer.cc:190
SyncRecordGenerator _syncGen
Definition: SyncServer.h:204
SampleClient * _sampleClient
Definition: SyncServer.h:219
static const float SORTER_LENGTH_SECS
Definition: SyncServer.h:169
SamplePipeline sorts samples that are coming from one or more inputs.
Definition: SamplePipeline.h:79
void init()
Call this method to parse the project, setup sample tags, preload calibrations using the time of the ...
Definition: SyncServer.cc:293
virtual ~StopSignal()
Definition: SyncServer.h:47
void setStopSignal(StopSignal *stop_signal)
Set a callback function which will be called when the SyncServer reaches EOF on its input stream or s...
Definition: SyncServer.h:156
SamplePipeline _pipeline
Definition: SyncServer.h:203
void setDataFileNames(const std::list< std::string > &dataFileNames)
Definition: SyncServer.h:143
void connect(SampleOutput *output)
Implementation of SampleConnectionRequester::connect().
Definition: SyncServer.cc:463
StopSignal()
Definition: SyncServer.h:42