📄 uaconfiguration.hxx
字号:
#ifndef UA_CONFIGURATION_HXX#define UA_CONFIGURATION_HXX/* ==================================================================== * The Vovida Software License, Version 1.0 * * Copyright (c) 2000 Vovida Networks, Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The names "VOCAL", "Vovida Open Communication Application Library", * and "Vovida Open Communication Application Library (VOCAL)" must * not be used to endorse or promote products derived from this * software without prior written permission. For written * permission, please contact vocal@vovida.org. * * 4. Products derived from this software may not be called "VOCAL", nor * may "VOCAL" appear in their name, without prior written * permission of Vovida Networks, Inc. * * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND * NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL VOVIDA * NETWORKS, INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT DAMAGES * IN EXCESS OF $1,000, NOR FOR ANY INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * DAMAGE. * * ==================================================================== * * This software consists of voluntary contributions made by Vovida * Networks, Inc. and many individuals on behalf of Vovida Networks, * Inc. For more information on Vovida Networks, Inc., please see * <http://www.vovida.org/>. * */static const char* const UaConfigurationVersion = "$Id: UaConfiguration.hxx,v 1.24 2002/03/19 21:40:17 jason Exp $";#include <string>#include <vector>#include "DigitCollector.hxx"namespace Vocal{typedef enum { XferOff = 0, XferOn = 1, ConfOn = 2} UaXferMode;/** * SIP User Agent configuration */class UaConfiguration{ public: /// // static const string DefaultRtpPort; /// static UaConfiguration* instance(); /// static void instance( const string cfgFile ); /// static void parseCfgFileCallBack( char* tag, char* type, char* value ); /// void show(); /// string getUserName(); /// string getPassword(); /// string getDisplayName(); /// string getLocalSipPort(); /// int getMinRtpPort(); /// int getMaxRtpPort(); /// string getSipTransport(); /// string getProxyServer(); /// bool getRegisterOn(); /// string getRegisterFrom(); /// string getRegisterTo(); /// int getRegisterExpires(); /// string getRegisterAction(); /// int getNetworkRtpRate(); /// bool getProvideRingback(); /// int getInitialDigitTimeout(); /// int getInterDigitTimeout(); /// UaXferMode getXferMode() const; /// string getConfServer() const; /// DialingPlanListType& getDialPlans(); /// SpeedDialMapType& getSpeedDials(); /// void setUserName( string name ); /// void setPassword( string pwd ); /// void setDisplayName( string name ); /// void setLocalSipPort( string port ); /// void setMinRtpPort( int port ); /// void setMaxRtpPort( int port ); /// void setSipTransport( string transport ); /// void setProxyServer( string server ); /// void setRegisterOn( bool on ); /// void setRegisterFrom( string from ); /// void setRegisterTo( string to ); /// void setRegisterExpires( int expires ); /// void setRegisterAction( string action ); /// void setNetworkRtpRate( int rate ); /// void setProvideRingback( bool ringback ); /// void setInitialDigitTimeout( int timeout ); /// void setInterDigitTimeout( int timeout ); /// void setXferMode( const UaXferMode xfermode ); /// void setConfServer( const string confserver ); /// void addDialPattern( DialMethodsType type, string pattern ); /// void addSpeedDial( string key, string dest ); /* begin load gen stuff */ /// bool getLoadGenOn(); /// string getRunMode(); /// int getStartTime(); /// int getNumKickStarts(); /// string getCallUrl(); /// int getNumEndpoints(); /// int getCallDuration(); /// int getCallDelay(); /// int getCallRestartTimer(); /// int getAnswerRestartTimer(); /// int getAnswerDelay(); /// bool getMonitorMsgOn(); /// int getMonitorMsgInterval(); /// string getDialNumber(); /// bool getRtpGenOn(); /// int getNumOfCalls(); /// bool getCJTimeOfDay(); /// void setLoadGenOn( bool on); /// void setRunMode( string mode); /// void setStartTime( int time); /// void setNumKickStarts( int num); /// void setCallUrl( string callUrl ); /// void setNumEndpoints( int endpoints); /// void setCallDuration( int duration); /// void setCallDelay( int delay); /// void setCallRestartTimer( int delay ); /// void setAnswerRestartTimer( int delay ); /// void setAnswerDelay(int ansDelay); /// void setMonitorMsgOn(bool msgOn); /// void setMonitorMsgInterval(int debugInt); /// void setDialNumber( string dialNum); /// void setRtpGenOn( bool rtpOn); /// void setNumOfCalls(int calls); /// void setCJTimeOfDay(bool cjOn); /* end load gen stuff */ /// bool getRsvpOn() const; /// string getProvisioningHost() const; /// int getProvisioningPort() const; /// bool getUsePolicyServer() const; /// string getDeviceName() const; /// bool getCallWaitingOn() const; /// void setRsvpOn( const bool on ); /// void setProvisioningHost( const string host ); /// void setProvisioningPort( const int port ); /// void setUsePolicyServer( const bool use ); /// void setDeviceName( const string devicename ); /// void setCallWaitingOn( const bool callwaiting ); /// void setCallIdOn( const bool callIdOn ); /// bool getCallIdOn(); /// void setCallId( const string callid ); /// string getCallId(); /// void setUaTimeout( const int timeout ); /// int getUaTimeout() const; /// void setSubscribeOn( const bool subOn ); /// bool getSubscribeOn() const; /// void setSubscribeExpire( const int expire ); /// int getSubscribeExpire() const; /// void setSubscribeTo( const string to ); /// string getSubscribeTo() const; /// void addVMServer(const string server); /// vector < string > & getVMServers(); /// set the filename that log messages should be sent to void setLogFilename(const string& filename); /// get the filename that log messages should be sent to string getLogFilename() const; /** set the NAT address, used to fill in the c= and o= lines in the SDP, so that RTP audio can tunnel through a NAT firewall. */ void setNATAddress(const string& address); /** get the NAT address */ string getNATAddress() const; /// ~UaConfiguration(); protected: /// private: /// UaConfiguration(); /// string userName; /// string displayName; /// string password; /// string localSipPort; /// int minRtpPort; /// int maxRtpPort; /// string sipTransport; /// string proxyServer; /// bool registerOn; /// string registerFrom; /// string registerTo; /// int registerExpires; /// string registerAction; /// int networkRtpRate; /// bool provideRingback; /// int initialDigitTimeout; /// int interDigitTimeout; /// DialingPlanListType dialPlans; /// SpeedDialMapType speedDials; /* begin load gen stuff */ /// bool loadGenOn; /// string runMode; /// int startTime; /// int numKickStarts; /// string callUrl; /// int numEndpoints; /// int callDuration; /// int callDelay; /// int callRestartTimer; /// int answerRestartTimer; /// int answerDelay; /// bool monitorMsgOn; /// int monitorMsgInterval; /// string dialNumber; /// bool rtpGenOn; /// int numOfCalls; /// bool cjTime; /* end load gen stuff */ /** * RSVP configuration data */ /// bool rsvpOn; /// string provisioningHost; /// int provisioningPort; /// bool usePolicyServer; /** * other parameters */ /// string deviceName; /// UaXferMode xferMode; /// string confServer; /// string myCallId; /// bool myCallIdOn; /// bool callWaitingOn; /// int uaTimeout; /// bool subscribeOn; /// int subscribeExpire; /// string subscribeTo; /// vector < string > myVmServers; string myLogFilename; string myNATAddress; /// static UaConfiguration* uaConfiguration;}; }/* Local Variables: *//* c-file-style: "stroustrup" *//* indent-tabs-mode: nil *//* c-file-offsets: ((access-label . -) (inclass . ++)) *//* c-basic-offset: 4 *//* End: */#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -