summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Client')
-rw-r--r--Swiften/Client/Client.cpp4
-rw-r--r--Swiften/Client/Client.h2
2 files changed, 6 insertions, 0 deletions
diff --git a/Swiften/Client/Client.cpp b/Swiften/Client/Client.cpp
index 5d04a92..60dfade 100644
--- a/Swiften/Client/Client.cpp
+++ b/Swiften/Client/Client.cpp
@@ -24,6 +24,10 @@ Client::~Client() {
delete connectionFactory_;
}
+bool Client::isAvailable() {
+ return session_;
+}
+
void Client::connect() {
DomainNameResolver resolver;
try {
diff --git a/Swiften/Client/Client.h b/Swiften/Client/Client.h
index 516bee2..59e1c05 100644
--- a/Swiften/Client/Client.h
+++ b/Swiften/Client/Client.h
@@ -30,6 +30,8 @@ namespace Swift {
void connect();
void disconnect();
+
+ bool isAvailable();
virtual void sendIQ(boost::shared_ptr<IQ>);
virtual void sendMessage(boost::shared_ptr<Message>);