diff options
Diffstat (limited to 'Swiften/Queries')
-rw-r--r-- | Swiften/Queries/IQChannel.h | 2 | ||||
-rw-r--r-- | Swiften/Queries/IQRouter.cpp | 4 | ||||
-rw-r--r-- | Swiften/Queries/IQRouter.h | 2 |
3 files changed, 8 insertions, 0 deletions
diff --git a/Swiften/Queries/IQChannel.h b/Swiften/Queries/IQChannel.h index 0dbb1be..1692afe 100644 --- a/Swiften/Queries/IQChannel.h +++ b/Swiften/Queries/IQChannel.h @@ -14,6 +14,8 @@ namespace Swift { virtual void sendIQ(boost::shared_ptr<IQ>) = 0; virtual String getNewIQID() = 0; + + virtual bool isAvailable() = 0; boost::signal<void (boost::shared_ptr<IQ>)> onIQReceived; }; diff --git a/Swiften/Queries/IQRouter.cpp b/Swiften/Queries/IQRouter.cpp index b20d344..ffed5f7 100644 --- a/Swiften/Queries/IQRouter.cpp +++ b/Swiften/Queries/IQRouter.cpp @@ -19,6 +19,10 @@ IQRouter::IQRouter(IQChannel* channel) : channel_(channel), queueRemoves_(false) IQRouter::~IQRouter() { } +bool IQRouter::isAvailable() { + return channel_->isAvailable(); +} + void IQRouter::handleIQ(boost::shared_ptr<IQ> iq) { queueRemoves_ = true; diff --git a/Swiften/Queries/IQRouter.h b/Swiften/Queries/IQRouter.h index 6de2ff9..717a845 100644 --- a/Swiften/Queries/IQRouter.h +++ b/Swiften/Queries/IQRouter.h @@ -23,6 +23,8 @@ namespace Swift { void sendIQ(boost::shared_ptr<IQ> iq); String getNewIQID(); + + bool isAvailable(); private: void handleIQ(boost::shared_ptr<IQ> iq); |