⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sipsmcommand.h

📁 MiniSip Client with DomainKeys Authentication, Sip, Audio communications, Echo Cancel
💻 H
字号:
/*  Copyright (C) 2005, 2004 Erik Eliasson, Johan Bilien    This library is free software; you can redistribute it and/or  modify it under the terms of the GNU Lesser General Public  License as published by the Free Software Foundation; either  version 2.1 of the License, or (at your option) any later version.  This library is distributed in the hope that it will be useful,  but WITHOUT ANY WARRANTY; without even the implied warranty of  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU  Lesser General Public License for more details.  You should have received a copy of the GNU Lesser General Public  License along with this library; if not, write to the Free Software  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA*//* * Authors: Erik Eliasson <eliasson@it.kth.se> *          Johan Bilien <jobi@via.ecp.fr>*/#ifndef SIPSMCOMMAND_H#define SIPSMCOMMAND_H#include<libmsip/libmsip_config.h>#include<libmsip/SipMessage.h>#include<libmutil/CommandString.h>#include<libmutil/MemObject.h>/** * The object used to communicate in Minisip. * The communication between the differet components always happens * via a <code>SipSMCommand</code> object that can contain a SIP message * or a command string.<p> * * @author Erik Eliasson <eliasson@it.kth.se> */class LIBMSIP_API SipSMCommand : public MObject{	public:		static const int COMMAND_PACKET;		static const int COMMAND_STRING;		static const int transport_layer;		static const int dialog_layer;		static const int transaction_layer;		static const int dispatcher;    ///SipCommandDispatcher; manages transactions and dialogs. Transactions/dialogs						///tell it when they						//terminate.		/**		 * Constructor.		 * @param cmd		 * @param source		 * @param destination		 */		SipSMCommand(const CommandString &cmd, int source, int destination);				/**		 * Constructor.		 * @param cmd		 * @param source		 * @param destination		 */		SipSMCommand(MRef<SipMessage*> cmd, int source, int destination);		virtual std::string getMemObjectType(){return "SipSMCommand";}		int getType() const;		int getSource() const;		void setSource(int s);		int getDestination() const;		void setDestination(int s);		MRef<SipMessage*> getCommandPacket() const;		CommandString getCommandString() const;#ifdef _WIN32_WCE        friend LIBMSIP_API Dbg & operator<<(Dbg &, const SipSMCommand &);	
#else        friend LIBMSIP_API std::ostream & operator<<(std::ostream &, const SipSMCommand &);
#endif	private:		int type;		CommandString cmdstr;		MRef<SipMessage*> cmdpkt;		int source;		int destination;};/** * the receiver for SipSMCommand objects. */class LIBMSIP_API SipSMCommandReceiver : public virtual MObject{	public:		/**		 * handles the incoming commands.		 * @param cmd a SipSMCommand		 * @return true if the command was handled.		 */		virtual bool handleCommand(const SipSMCommand &cmd)=0;};#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -