summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Network/Connection.h')
-rw-r--r--Swiften/Network/Connection.h56
1 files changed, 28 insertions, 28 deletions
diff --git a/Swiften/Network/Connection.h b/Swiften/Network/Connection.h
index 39b63d4..c38b98f 100644
--- a/Swiften/Network/Connection.h
+++ b/Swiften/Network/Connection.h
@@ -13,32 +13,32 @@
#include <Swiften/Base/boost_bsignals.h>
namespace Swift {
- class HostAddressPort;
-
- class SWIFTEN_API Connection {
- public:
- typedef boost::shared_ptr<Connection> ref;
-
- enum Error {
- ReadError,
- WriteError
- };
-
- Connection();
- virtual ~Connection();
-
- virtual void listen() = 0;
- virtual void connect(const HostAddressPort& address) = 0;
- virtual void disconnect() = 0;
- virtual void write(const SafeByteArray& data) = 0;
-
- virtual HostAddressPort getLocalAddress() const = 0;
- virtual HostAddressPort getRemoteAddress() const = 0;
-
- public:
- boost::signal<void (bool /* error */)> onConnectFinished;
- boost::signal<void (const boost::optional<Error>&)> onDisconnected;
- boost::signal<void (boost::shared_ptr<SafeByteArray>)> onDataRead;
- boost::signal<void ()> onDataWritten;
- };
+ class HostAddressPort;
+
+ class SWIFTEN_API Connection {
+ public:
+ typedef boost::shared_ptr<Connection> ref;
+
+ enum Error {
+ ReadError,
+ WriteError
+ };
+
+ Connection();
+ virtual ~Connection();
+
+ virtual void listen() = 0;
+ virtual void connect(const HostAddressPort& address) = 0;
+ virtual void disconnect() = 0;
+ virtual void write(const SafeByteArray& data) = 0;
+
+ virtual HostAddressPort getLocalAddress() const = 0;
+ virtual HostAddressPort getRemoteAddress() const = 0;
+
+ public:
+ boost::signal<void (bool /* error */)> onConnectFinished;
+ boost::signal<void (const boost::optional<Error>&)> onDisconnected;
+ boost::signal<void (boost::shared_ptr<SafeByteArray>)> onDataRead;
+ boost::signal<void ()> onDataWritten;
+ };
}