libkdegames/kggznet
kggzpacket.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef KGGZPACKET_H
00022 #define KGGZPACKET_H
00023
00024 #include <QtCore/QObject>
00025 #include <QtCore/QDataStream>
00026
00027 #include "kggznet_export.h"
00028
00029 class QAbstractSocket;
00030
00054 class KGGZNET_EXPORT KGGZPacket : public QObject
00055 {
00056 Q_OBJECT
00057 public:
00064 KGGZPacket();
00065
00072 ~KGGZPacket();
00073
00083 QDataStream *inputstream();
00084
00093 QDataStream *outputstream();
00094
00101 void flush();
00102
00103 public slots:
00113 void slotNetwork(int fd);
00114
00115 signals:
00122 void signalPacket();
00123
00124 private:
00125 QDataStream *m_inputstream, *m_outputstream;
00126 QAbstractSocket *m_socket;
00127 QByteArray m_input, m_output;
00128 int m_size;
00129 };
00130
00131 #endif
00132