Rev | Line | |
---|
[35] | 1 |
|
---|
| 2 | #ifndef BNCCASTER_H
|
---|
| 3 | #define BNCCASTER_H
|
---|
| 4 |
|
---|
| 5 | #include <QFile>
|
---|
| 6 | #include <QThread>
|
---|
| 7 | #include <QtNetwork>
|
---|
| 8 | #include <QMultiMap>
|
---|
| 9 |
|
---|
| 10 | #include "RTCM/GPSDecoder.h"
|
---|
| 11 |
|
---|
| 12 | class bncGetThread;
|
---|
| 13 |
|
---|
| 14 | class bncCaster : public QThread {
|
---|
| 15 | Q_OBJECT
|
---|
| 16 |
|
---|
| 17 | public:
|
---|
| 18 | bncCaster(const QString& outFileName, int port);
|
---|
| 19 | ~bncCaster();
|
---|
| 20 | void addGetThread(bncGetThread* getThread);
|
---|
| 21 |
|
---|
| 22 | signals:
|
---|
| 23 | void getThreadErrors();
|
---|
| 24 |
|
---|
| 25 | public slots:
|
---|
| 26 | void slotNewObs(const QByteArray& mountPoint, Observation* obs);
|
---|
| 27 |
|
---|
| 28 | private slots:
|
---|
| 29 | void slotNewConnection();
|
---|
| 30 | void slotGetThreadError(const QByteArray& mountPoint);
|
---|
| 31 |
|
---|
| 32 | protected:
|
---|
| 33 | virtual void run();
|
---|
| 34 |
|
---|
| 35 | private:
|
---|
| 36 | void dumpEpochs(long minTime, long maxTime);
|
---|
| 37 |
|
---|
| 38 | QFile* _outFile;
|
---|
| 39 | int _port;
|
---|
| 40 | QTextStream* _out;
|
---|
| 41 | QMultiMap<long, Observation*>* _epochs;
|
---|
| 42 | long _lastDumpSec;
|
---|
| 43 | QTcpServer* _server;
|
---|
| 44 | QList<QTcpSocket*>* _sockets;
|
---|
| 45 | QList<QByteArray> _mountPoints;
|
---|
| 46 | };
|
---|
| 47 |
|
---|
| 48 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.