diff options
Diffstat (limited to 'Swiften/Queries/Responder.h')
-rw-r--r-- | Swiften/Queries/Responder.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Swiften/Queries/Responder.h b/Swiften/Queries/Responder.h index a9aab17..2ba9c24 100644 --- a/Swiften/Queries/Responder.h +++ b/Swiften/Queries/Responder.h @@ -88,18 +88,22 @@ namespace Swift { } /** * Convenience function for responding with an error from a specific from address. */ void sendError(const JID& to, const JID& from, const std::string& id, ErrorPayload::Condition condition, ErrorPayload::Type type) { router_->sendIQ(IQ::createError(to, from, id, condition, type)); } + IQRouter* getIQRouter() const { + return router_; + } + private: virtual bool handleIQ(boost::shared_ptr<IQ> iq) { if (iq->getType() == IQ::Set || iq->getType() == IQ::Get) { boost::shared_ptr<PAYLOAD_TYPE> payload(iq->getPayload<PAYLOAD_TYPE>()); if (payload) { bool result; if (iq->getType() == IQ::Set) { result = handleSetRequest(iq->getFrom(), iq->getTo(), iq->getID(), payload); } |