/* * Copyright (c) 2012 Mateusz Piękos * Licensed under the simplified BSD license. * See Documentation/Licenses/BSD-simplified.txt for more information. */ #pragma once #include #include #include #include namespace Swift { class IQRouter; class ErrorPayload; class WhiteboardPayload; class WhiteboardSession { public: WhiteboardSession(const JID& jid, IQRouter* router); void handleIncomingAction(boost::shared_ptr payload); void sendData(const std::string& data); void sendSessionRequest(); void handleSessionRequestResponse(boost::shared_ptr whiteboardPayload, boost::shared_ptr errorPayload); public: boost::signal< void(const std::string& data)> onDataReceived; boost::signal< void(const JID& contact, WhiteboardSession* session)> onRequestAccepted; private: JID toJID_; IQRouter* router_; GenericRequest* sessionRequest; }; }