source: ntrip/trunk/BNC/bncsocket.h@ 1362

Last change on this file since 1362 was 1362, checked in by mervart, 16 years ago

* empty log message *

File size: 1.1 KB
RevLine 
[1344]1#ifndef BNCSOCKET_H
2#define BNCSOCKET_H
3
4#include <QtNetwork>
[1349]5#include "bncconst.h"
[1344]6
[1362]7class bncSocket : public QObject {
[1354]8 Q_OBJECT
[1344]9
10 public:
[1349]11 bncSocket();
[1344]12 ~bncSocket();
13
[1345]14 void close();
15 qint64 bytesAvailable() const;
16 bool canReadLine() const;
17 QByteArray readLine(qint64 maxlen = 0);
18 bool waitForReadyRead(int msecs = 30000);
19 qint64 read(char *data, qint64 maxlen);
[1344]20 QAbstractSocket::SocketState state() const;
21
[1349]22 t_irc request(const QUrl& mountPoint, const QByteArray& latitude,
23 const QByteArray& longitude, const QByteArray& nmea,
[1353]24 const QByteArray& ntripVersion, int timeOut, QString& msg);
[1346]25
[1354]26 signals:
[1362]27 void quitEventLoop();
[1354]28 void newMessage(QByteArray msg, bool showOnScreen);
29
[1355]30 private slots:
[1357]31 void slotDone(bool);
32 void slotRequestFinished(int, bool);
[1360]33 void slotReadyRead();
[1355]34
[1344]35 private:
[1356]36 t_irc request2(const QUrl& url, const QByteArray& latitude,
[1355]37 const QByteArray& longitude, const QByteArray& nmea,
38 int timeOut, QString& msg);
39
[1357]40 QTcpSocket* _socket;
41 QHttp* _http;
[1360]42 QBuffer* _buffer;
[1362]43 QEventLoop* _eventLoop;
[1344]44};
45
46#endif
Note: See TracBrowser for help on using the repository browser.