summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Server/ServerFromClientSession.h')
-rw-r--r--Swiften/Server/ServerFromClientSession.h22
1 files changed, 2 insertions, 20 deletions
diff --git a/Swiften/Server/ServerFromClientSession.h b/Swiften/Server/ServerFromClientSession.h
index 733c428..213f5c7 100644
--- a/Swiften/Server/ServerFromClientSession.h
+++ b/Swiften/Server/ServerFromClientSession.h
@@ -5,6 +5,7 @@
#include <boost/enable_shared_from_this.hpp>
#include "Swiften/Base/String.h"
+#include "Swiften/Session/Session.h"
#include "Swiften/JID/JID.h"
#include "Swiften/Network/Connection.h"
@@ -21,7 +22,7 @@ namespace Swift {
class Connection;
class ByteArray;
- class ServerFromClientSession : public boost::enable_shared_from_this<ServerFromClientSession> {
+ class ServerFromClientSession : public Session {
public:
ServerFromClientSession(
const String& id,
@@ -29,11 +30,6 @@ namespace Swift {
PayloadParserFactoryCollection* payloadParserFactories,
PayloadSerializerCollection* payloadSerializers,
UserRegistry* userRegistry);
- ~ServerFromClientSession();
-
- void start();
-
- void sendStanza(boost::shared_ptr<Stanza>);
const JID& getJID() const {
return jid_;
@@ -43,28 +39,14 @@ namespace Swift {
return domain_;
}
- boost::signal<void (boost::shared_ptr<Stanza>)> onStanzaReceived;
- boost::signal<void ()> onSessionFinished;
- boost::signal<void ()> onSessionStarted;
- boost::signal<void (const ByteArray&)> onDataWritten;
- boost::signal<void (const ByteArray&)> onDataRead;
-
private:
- void handleDisconnected(const boost::optional<Connection::Error>& error);
void handleElement(boost::shared_ptr<Element>);
void handleStreamStart(const ProtocolHeader& header);
private:
String id_;
- boost::shared_ptr<Connection> connection_;
- PayloadParserFactoryCollection* payloadParserFactories_;
- PayloadSerializerCollection* payloadSerializers_;
UserRegistry* userRegistry_;
bool authenticated_;
- bool initialized_;
- boost::shared_ptr<XMPPLayer> xmppLayer_;
- boost::shared_ptr<ConnectionLayer> connectionLayer_;
- StreamStack* streamStack_;
JID domain_;
String user_;
JID jid_;