summaryrefslogtreecommitdiffstats
path: root/signet/Table.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'signet/Table.cpp')
-rw-r--r--signet/Table.cpp23
1 files changed, 15 insertions, 8 deletions
diff --git a/signet/Table.cpp b/signet/Table.cpp
index 1296e825..5cd6373d 100644
--- a/signet/Table.cpp
+++ b/signet/Table.cpp
@@ -18,18 +18,25 @@
// Header include
#include "Table.h"
+// Protocol includes
+#include "protocol/PacketMaker.h"
+
+// Qt includes
+#include <QtNetwork/QTcpSocket>
+
Signet::Table::Table(const QString& name, QObject* parent) :
- ConnectionHandler(parent),
+ ClientHandler(parent),
m_name(name)
{
}
-QString Signet::Table::type() const
-{
- return "table";
-}
-
-QString Signet::Table::name() const
+void Signet::Table::packetReceived(QTcpSocket* client, Protocol::Packet* packet)
{
- return m_name;
+ QString receiver = packet->received();
+ if (receiver.isEmpty())
+ {
+ // TODO: Handle the packet
+ }
+ else
+ Protocol::PacketMaker::unknownReceiver(client);
}