mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-02-07 14:18:25 +00:00
Use common syntax for linphone-daemon commands documentation.
This commit is contained in:
parent
e5ac143a2c
commit
91324fa520
33 changed files with 54 additions and 57 deletions
|
|
@ -67,10 +67,9 @@ void AdaptiveBufferCompensationResponse::outputAdaptiveBufferCompensation(Linpho
|
|||
}
|
||||
|
||||
AdaptiveBufferCompensationCommand::AdaptiveBufferCompensationCommand() :
|
||||
DaemonCommand("adaptive-jitter-compensation", "adaptive-jitter-compensation [<stream>] [enable|disable]",
|
||||
"Enable or disable adaptive buffer compensation respectively with the 'enable' and 'disable' parameters for the specified stream, "
|
||||
"return the status of the use of adaptive buffer compensation without parameter.\n"
|
||||
"<stream> must be one of these values: audio, video.") {
|
||||
DaemonCommand("adaptive-jitter-compensation", "adaptive-jitter-compensation [audio|video] [enable|disable]",
|
||||
"Enable or disable adaptive buffer compensation respectively with the 'enable' and 'disable' parameters for the specified stream, "
|
||||
"return the status of the use of adaptive buffer compensation without parameter.") {
|
||||
addExample(new DaemonCommandExample("adaptive-jitter-compensation audio",
|
||||
"Status: Ok\n\n"
|
||||
"Audio: enabled"));
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AnswerCommand::AnswerCommand() :
|
||||
DaemonCommand("answer", "answer <call id>", "Answer an incoming call.") {
|
||||
DaemonCommand("answer", "answer <call_id>", "Answer an incoming call.") {
|
||||
addExample(new DaemonCommandExample("answer 3",
|
||||
"Status: Error\n"
|
||||
"Reason: No call with such id."));
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioCodecGetCommand::AudioCodecGetCommand() :
|
||||
DaemonCommand("audio-codec-get", "audio-codec-get <payload_type_number|mime_type>",
|
||||
DaemonCommand("audio-codec-get", "audio-codec-get <payload_type_number>|<mime_type>",
|
||||
"Get an audio codec if a parameter is given, otherwise return the audio codec list.\n"
|
||||
"<mime_type> is of the form mime/rate/channels, eg. speex/16000/1") {
|
||||
addExample(new DaemonCommandExample("audio-codec-get 9",
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioCodecMoveCommand::AudioCodecMoveCommand() :
|
||||
DaemonCommand("audio-codec-move", "audio-codec-move <payload_type_number|mime_type> <index>",
|
||||
DaemonCommand("audio-codec-move", "audio-codec-move <payload_type_number>|<mime_type> <index>",
|
||||
"Move a codec to the specified index.\n"
|
||||
"<mime_type> is of the form mime/rate/channels, eg. speex/16000/1") {
|
||||
addExample(new DaemonCommandExample("audio-codec-move 9 1",
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioCodecSetCommand::AudioCodecSetCommand() :
|
||||
DaemonCommand("audio-codec-set", "audio-codec-set <payload_type_number|mime_type> <property> <value>",
|
||||
DaemonCommand("audio-codec-set", "audio-codec-set <payload_type_number>|<mime_type> <property> <value>",
|
||||
"Set a property (number, clock_rate, recv_fmtp, send_fmtp, bitrate (in kbps/s)) of a codec. Numbering of payload type is automatically performed at startup, any change will be lost after restart.\n"
|
||||
"<mime_type> is of the form mime/rate/channels, eg. speex/16000/1") {
|
||||
addExample(new DaemonCommandExample("audio-codec-set 9 number 18",
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ void AudioCodecToggleCommand::exec(Daemon *app, const string& args) {
|
|||
}
|
||||
|
||||
AudioCodecEnableCommand::AudioCodecEnableCommand() :
|
||||
AudioCodecToggleCommand("audio-codec-enable", "audio-codec-enable <payload_type_number|mime_type|ALL>",
|
||||
AudioCodecToggleCommand("audio-codec-enable", "audio-codec-enable <payload_type_number>|<mime_type>|ALL",
|
||||
"Enable an audio codec.\n"
|
||||
"<mime_type> is of the form mime/rate/channels, eg. speex/16000/1", true) {
|
||||
addExample(new DaemonCommandExample("audio-codec-enable G722/8000/1",
|
||||
|
|
@ -94,7 +94,7 @@ AudioCodecEnableCommand::AudioCodecEnableCommand() :
|
|||
}
|
||||
|
||||
AudioCodecDisableCommand::AudioCodecDisableCommand() :
|
||||
AudioCodecToggleCommand("audio-codec-disable", "audio-codec-disable <payload_type_number|mime_type|ALL>",
|
||||
AudioCodecToggleCommand("audio-codec-disable", "audio-codec-disable <payload_type_number>|<mime_type>|ALL",
|
||||
"Disable an audio codec.\n"
|
||||
"<mime_type> is of the form mime/rate/channels, eg. speex/16000/1", false) {
|
||||
addExample(new DaemonCommandExample("audio-codec-disable G722/8000/1",
|
||||
|
|
@ -119,4 +119,4 @@ AudioCodecDisableCommand::AudioCodecDisableCommand() :
|
|||
"Recv-fmtp: \n"
|
||||
"Send-fmtp: \n"
|
||||
"Enabled: false"));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioStreamStartCommand::AudioStreamStartCommand() :
|
||||
DaemonCommand("audio-stream-start", "audio-stream-start <remote ip> <remote port> <payload type number>", "Start an audio stream.") {
|
||||
DaemonCommand("audio-stream-start", "audio-stream-start <remote_ip> <remote_port> <payload_type_number>", "Start an audio stream.") {
|
||||
addExample(new DaemonCommandExample("audio-stream-start 192.168.1.28 7078 9",
|
||||
"Status: Ok\n\n"
|
||||
"Id: 1"));
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioStreamStatsCommand::AudioStreamStatsCommand() :
|
||||
DaemonCommand("audio-stream-stats", "audio-stream-stats <stream id>", "Return stats of a given audio stream.") {
|
||||
DaemonCommand("audio-stream-stats", "audio-stream-stats <stream_id>", "Return stats of a given audio stream.") {
|
||||
addExample(new DaemonCommandExample("audio-stream-stats 1",
|
||||
"Status: Ok\n\n"
|
||||
"Audio-ICE state: Not activated\n"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AudioStreamStopCommand::AudioStreamStopCommand() :
|
||||
DaemonCommand("audio-stream-stop", "audio-stream-stop <audio stream id>", "Stop an audio stream.") {
|
||||
DaemonCommand("audio-stream-stop", "audio-stream-stop <stream_id>", "Stop an audio stream.") {
|
||||
addExample(new DaemonCommandExample("audio-stream-stop 1",
|
||||
"Status: Ok"));
|
||||
addExample(new DaemonCommandExample("audio-stream-stop 2",
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
AuthInfosClearCommand::AuthInfosClearCommand() :
|
||||
DaemonCommand("auth-infos-clear", "auth-infos-clear <auth_infos_id|ALL> ", "Remove auth infos context for the given id, or all.") {
|
||||
DaemonCommand("auth-infos-clear", "auth-infos-clear <auth_infos_id>|ALL", "Remove auth infos context for the given id, or all.") {
|
||||
addExample(new DaemonCommandExample("auth-infos-clear 1",
|
||||
"Status: Ok\n"
|
||||
"Reason: Successfully cleared auth info 1."));
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
CallMuteCommand::CallMuteCommand() :
|
||||
DaemonCommand("call-mute", "call-mute 0|1", "mute/unmute the microphone (1 to mute, 0 to unmute). No argument means MUTE.")
|
||||
DaemonCommand("call-mute", "call-mute 0|1", "Mute/unmute the microphone (1 to mute, 0 to unmute). No argument means MUTE.")
|
||||
{
|
||||
addExample(new DaemonCommandExample("call-mute 1",
|
||||
"Status: Ok\n\n"
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ using namespace std;
|
|||
|
||||
CallPauseCommand::CallPauseCommand() :
|
||||
DaemonCommand("call-pause",
|
||||
"call-pause <call id>",
|
||||
"call-pause [<call_id>]",
|
||||
"Pause a call (pause current if no id is specified).")
|
||||
{
|
||||
addExample(new DaemonCommandExample("call-pause 1",
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
CallResumeCommand::CallResumeCommand():
|
||||
DaemonCommand("call-resume", "call-resume <call id>", "Pause a call (pause current if no id is specified).")
|
||||
DaemonCommand("call-resume", "call-resume [<call_id>]", "Pause a call (pause current if no id is specified).")
|
||||
{
|
||||
addExample(new DaemonCommandExample("call-resume 1",
|
||||
"Status: Ok\n\n"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
CallStatsCommand::CallStatsCommand() :
|
||||
DaemonCommand("call-stats", "call-stats <call id>", "Return all stats of a call.") {
|
||||
DaemonCommand("call-stats", "call-stats [<call_id>]", "Return all stats of a call.") {
|
||||
addExample(new DaemonCommandExample("call-stats 1",
|
||||
"Status: Ok\n\n"
|
||||
"Audio-ICE state: Not activated\n"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
CallStatusCommand::CallStatusCommand() :
|
||||
DaemonCommand("call-status", "call-status <call id>", "Return status of a call.") {
|
||||
DaemonCommand("call-status", "call-status [<call_id>]", "Return status of a call.") {
|
||||
addExample(new DaemonCommandExample("call-status 1",
|
||||
"Status: Ok\n\n"
|
||||
"State: LinphoneCallStreamsRunning\n"
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ using namespace std;
|
|||
|
||||
CallTransferCommand::CallTransferCommand() :
|
||||
DaemonCommand("call-transfer",
|
||||
"call-transfer <call_to_transfer_id> <call_to_transfer_to_id|sip_url_to_transfer_to>",
|
||||
"call-transfer <call_to_transfer_id> <call_to_transfer_to_id>|<sip_url_to_transfer_to>",
|
||||
"Transfer a call that you aswered to another party")
|
||||
{
|
||||
addExample(new DaemonCommandExample("call-transfer 1 sip:john",
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
CallCommand::CallCommand() :
|
||||
DaemonCommand("call", "call <sip address>", "Place a call.") {
|
||||
DaemonCommand("call", "call <sip_address> [--early-media]", "Place a call.") {
|
||||
addExample(new DaemonCommandExample("call daemon-test@sip.linphone.org",
|
||||
"Status: Ok\n\n"
|
||||
"Id: 1"));
|
||||
|
|
|
|||
|
|
@ -22,13 +22,13 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
ConferenceCommand::ConferenceCommand() :
|
||||
DaemonCommand("conference", "conference <subcommand> <call id>",
|
||||
DaemonCommand("conference", "conference add|rm|leave|enter <call_id>",
|
||||
"Create and manage an audio conference.\n"
|
||||
"Subcommands:\n"
|
||||
"You can:\n"
|
||||
"- add : join the call with id 'call id' into the audio conference. Creates new one if none exists.\n"
|
||||
"- rm : remove the call with id 'call id' from the audio conference\n"
|
||||
"- rm : remove the call with id 'call id' from the audio conference.\n"
|
||||
"- leave : temporarily leave the current conference.\n"
|
||||
"- enter : re-join the conference after leaving it")
|
||||
"- enter : re-join the conference after leaving it.")
|
||||
{
|
||||
addExample(new DaemonCommandExample("conference add 1",
|
||||
"Status: Ok\n\n"
|
||||
|
|
|
|||
|
|
@ -33,9 +33,9 @@ ConfigResponse::ConfigResponse(const string& value) : Response() {
|
|||
}
|
||||
|
||||
ConfigGetCommand::ConfigGetCommand() :
|
||||
DaemonCommand("config-get", "config section key",
|
||||
DaemonCommand("config-get", "config-get <section> <key>",
|
||||
"Reads a configuration value from linphone's configuration database.") {
|
||||
addExample(new DaemonCommandExample("config rtp symmetric",
|
||||
addExample(new DaemonCommandExample("config-get rtp symmetric",
|
||||
"Status: Ok\n\n"
|
||||
"Value: <unset>"));
|
||||
}
|
||||
|
|
@ -54,7 +54,7 @@ void ConfigGetCommand::exec(Daemon *app, const string& args) {
|
|||
|
||||
|
||||
ConfigSetCommand::ConfigSetCommand() :
|
||||
DaemonCommand("config-set", "config section key value",
|
||||
DaemonCommand("config-set", "config-set <section> <key> <value>",
|
||||
"Sets a configuration value into linphone's configuration database.") {
|
||||
addExample(new DaemonCommandExample("config-set rtp symmetric 1",
|
||||
"Status: Ok\n\n"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
ContactCommand::ContactCommand() :
|
||||
DaemonCommand("contact", "contact sip:<username>@<hostname> or contact username hostname", "Set a contact name.") {
|
||||
DaemonCommand("contact", "contact <sip_address> or contact <username> <hostname>", "Set a contact name.") {
|
||||
addExample(new DaemonCommandExample("contact sip:root@unknown-host",
|
||||
"Status: Ok\n\n"));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
DtmfCommand::DtmfCommand() :
|
||||
DaemonCommand("dtmf", "dtmf <digit>", "Generate a DTMF (one of: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, *, #.") {
|
||||
DaemonCommand("dtmf", "dtmf <digit>", "Generate a DTMF (one of 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, *, #).") {
|
||||
addExample(new DaemonCommandExample("dtmf 4",
|
||||
"Status: Ok"));
|
||||
addExample(new DaemonCommandExample("dtmf B",
|
||||
|
|
|
|||
|
|
@ -54,9 +54,8 @@ FirewallPolicyResponse::FirewallPolicyResponse(LinphoneCore *core) : Response()
|
|||
}
|
||||
|
||||
FirewallPolicyCommand::FirewallPolicyCommand() :
|
||||
DaemonCommand("firewall-policy", "firewall-policy <type> [<address>]",
|
||||
DaemonCommand("firewall-policy", "firewall-policy [none|nat|stun|ice|upnp] [<address>]",
|
||||
"Set the firewall policy if type is set, otherwise return the used firewall policy.\n"
|
||||
"<type> must be one of these values: none, nat, stun, ice, upnp.\n"
|
||||
"<address> must be specified for the 'nat' and 'stun' types. "
|
||||
"It represents the public address of the gateway for the 'nat' type and the STUN server address for the 'stun' and 'ice' types.") {
|
||||
addExample(new DaemonCommandExample("firewall-policy stun stun.linphone.org",
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
HelpCommand::HelpCommand() :
|
||||
DaemonCommand("help", "help <command>", "Show <command> help notice, if command is unspecified or inexistent show all commands.") {
|
||||
DaemonCommand("help", "help [<command>]", "Show <command> help notice, if command is unspecified or inexistent show all commands.") {
|
||||
}
|
||||
|
||||
void HelpCommand::exec(Daemon *app, const string& args) {
|
||||
|
|
|
|||
|
|
@ -38,10 +38,10 @@ public:
|
|||
};
|
||||
|
||||
JitterBufferCommand::JitterBufferCommand() : DaemonCommand("jitter-buffer",
|
||||
"jitter-buffer <stream-type> [size <milliseconds>]" ,
|
||||
"jitter-buffer [audio|video] [size <milliseconds>]",
|
||||
"Control jitter buffer parameters.\n"
|
||||
"jitter-buffer <stream-type> size <milliseconds> : sets the nominal jitter buffer size in milliseconds. Has no effect in a running call.\n"
|
||||
"jitter-buffer <stream-type> : gets the nominal jitter buffer size."
|
||||
"jitter-buffer [audio|video] size <milliseconds>: sets the nominal jitter buffer size in milliseconds. Has no effect in a running call.\n"
|
||||
"jitter-buffer [audio|video]: gets the nominal jitter buffer size."
|
||||
){
|
||||
addExample(new DaemonCommandExample("jitter-buffer","Status: Ok\n\n"
|
||||
"audio-jitter-buffer-size: 60\nvideo-jitter-buffer-size: 60\n"));
|
||||
|
|
@ -86,7 +86,7 @@ void JitterBufferCommand::exec(Daemon *app, const string& args) {
|
|||
}
|
||||
|
||||
JitterBufferResetCommand::JitterBufferResetCommand() : DaemonCommand("jitter-buffer-reset",
|
||||
"jitter-buffer-reset [call|stream] id [audio|video]" ,
|
||||
"jitter-buffer-reset call|stream <id> [audio|video]" ,
|
||||
"Reset the RTP jitter buffer for a given call or stream id and stream type."
|
||||
){
|
||||
addExample(new DaemonCommandExample("jitter-buffer-reset call 3 audio",
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
MSFilterAddFmtpCommand::MSFilterAddFmtpCommand() :
|
||||
DaemonCommand("msfilter-add-fmtp", "msfilter-add-fmtp <call/stream> <id> <fmtp>", "Add fmtp to the encoder of a call or a stream") {
|
||||
DaemonCommand("msfilter-add-fmtp", "msfilter-add-fmtp call|stream <id> <fmtp>", "Add fmtp to the encoder of a call or a stream") {
|
||||
addExample(new DaemonCommandExample("msfilter-add-fmtp call 1 vbr=on",
|
||||
"Status: Ok"));
|
||||
addExample(new DaemonCommandExample("msfilter-add-fmtp call 2 vbr=on",
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ NetsimResponse::NetsimResponse(LinphoneCore *lc) : Response() {
|
|||
setBody(ost.str());
|
||||
}
|
||||
|
||||
NetsimCommand::NetsimCommand(): DaemonCommand("netsim","netsim [enabled|disabled|parameters <parameters]",
|
||||
NetsimCommand::NetsimCommand(): DaemonCommand("netsim","netsim [enable|disable|parameters] [<parameters>]",
|
||||
"Configure the network simulator. Parameters are to be provided in the form param-name=param-value, separated with ';' only. Supported parameters are:\n"
|
||||
"\tmax_bandwidth (kbit/s)\n"
|
||||
"\tmax_buffer_size (bits)\n"
|
||||
|
|
|
|||
|
|
@ -87,10 +87,9 @@ void PortResponse::outputVideoRTPPort(LinphoneCore *core, ostringstream &ost) {
|
|||
}
|
||||
|
||||
PortCommand::PortCommand() :
|
||||
DaemonCommand("port", "port [<type>] [<port>] [<protocol>]",
|
||||
DaemonCommand("port", "port [sip|audio|video] [<port>] [udp|tcp|tls]",
|
||||
"Set the port to use for type if port is set, otherwise return the port used for type if specified or all the used ports if no type is specified.\n"
|
||||
"<type> must be one of these values: sip, audio, video.\n"
|
||||
"<protocol> should be defined only for sip port and have one of these values: udp, tcp, tls.") {
|
||||
"The protocol should be defined only for sip port and have one of these values: udp, tcp, tls.") {
|
||||
addExample(new DaemonCommandExample("port sip 5060 tls",
|
||||
"Status: Ok\n\n"
|
||||
"SIP: 5060 TLS"));
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ PtimeResponse::PtimeResponse(LinphoneCore *core, Direction dir) : Response() {
|
|||
}
|
||||
|
||||
PtimeCommand::PtimeCommand() :
|
||||
DaemonCommand("ptime", "ptime [up|down] <ms>", "Set the upload or download ptime if ms is defined, otherwise return the current value of the ptime.") {
|
||||
DaemonCommand("ptime", "ptime [up|down] [<ms>]", "Set the upload or download ptime if ms is defined, otherwise return the current value of the ptime.") {
|
||||
addExample(new DaemonCommandExample("ptime up 20",
|
||||
"Status: Ok\n\n"
|
||||
"Upload: 20"));
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ void RegisterStatusResponse::append(int id, const LinphoneProxyConfig* cfg) {
|
|||
}
|
||||
|
||||
RegisterStatusCommand::RegisterStatusCommand() :
|
||||
DaemonCommand("register-status", "register-status <register_id|ALL>", "Return status of a registration or of all registrations.") {
|
||||
DaemonCommand("register-status", "register-status <register_id>|ALL", "Return status of a registration or of all registrations.") {
|
||||
addExample(new DaemonCommandExample("register-status 1",
|
||||
"Status: Ok\n\n"
|
||||
"Id: 1\n"
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
RegisterCommand::RegisterCommand() :
|
||||
DaemonCommand("register", "register <identity> <proxy-address> <password> <userid> <realm>", "Register the daemon to a SIP proxy. If one of the parameters <password>, <userid> and <realm> is not needed, send the string \"NULL\"") {
|
||||
DaemonCommand("register", "register <identity> <proxy_address> [<password>] [<userid>] [<realm>] [<parameter>]", "Register the daemon to a SIP proxy. If one of the parameters <password>, <userid> and <realm> is not needed, send the string \"NULL\"") {
|
||||
addExample(new DaemonCommandExample("register sip:daemon-test@sip.linphone.org sip.linphone.org password bob linphone.org",
|
||||
"Status: Ok\n\n"
|
||||
"Id: 1"));
|
||||
|
|
@ -61,9 +61,9 @@ void RegisterCommand::exec(Daemon *app, const string& args) {
|
|||
}
|
||||
cidentity = identity.c_str();
|
||||
cproxy = proxy.c_str();
|
||||
if (!password.empty()) cpassword = password.c_str();
|
||||
if (!userid.empty()) cuserid = userid.c_str();
|
||||
if (!realm.empty()) crealm = realm.c_str();
|
||||
if (!password.empty() && (password.compare("NULL") != 0)) cpassword = password.c_str();
|
||||
if (!userid.empty() && (userid.compare("NULL") != 0)) cuserid = userid.c_str();
|
||||
if (!realm.empty() && (realm.compare("NULL") != 0)) crealm = realm.c_str();
|
||||
if (!parameter.empty()) cparameter = parameter.c_str();
|
||||
LinphoneProxyConfig *cfg = linphone_proxy_config_new();
|
||||
if (cpassword != NULL) {
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
TerminateCommand::TerminateCommand() :
|
||||
DaemonCommand("terminate", "terminate <call id>", "Terminate a call.") {
|
||||
DaemonCommand("terminate", "terminate [<call_id>]", "Terminate a call.") {
|
||||
addExample(new DaemonCommandExample("terminate 2",
|
||||
"Status: Error\n"
|
||||
"Reason: No call with such id."));
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|||
using namespace std;
|
||||
|
||||
UnregisterCommand::UnregisterCommand() :
|
||||
DaemonCommand("unregister", "unregister <register_id|ALL>", "Unregister the daemon from the specified proxy or from all proxies.") {
|
||||
DaemonCommand("unregister", "unregister <register_id>|ALL", "Unregister the daemon from the specified proxy or from all proxies.") {
|
||||
addExample(new DaemonCommandExample("unregister 3",
|
||||
"Status: Error\n"
|
||||
"Reason: No register with such id."));
|
||||
|
|
|
|||
|
|
@ -23,9 +23,9 @@ using namespace std;
|
|||
|
||||
Video::Video() :
|
||||
DaemonCommand("video",
|
||||
"video <call id>",
|
||||
"Toggles camera on current call."
|
||||
"If no call is specified, the current call is taken.")
|
||||
"video [call_id]",
|
||||
"Toggles camera on current call."
|
||||
"If no call is specified, the current call is taken.")
|
||||
{
|
||||
addExample(new DaemonCommandExample("video 1",
|
||||
"Status: Ok\n\n"
|
||||
|
|
@ -85,7 +85,7 @@ void Video::exec(Daemon* app, const string& args)
|
|||
|
||||
VideoSource::VideoSource():
|
||||
DaemonCommand("videosource",
|
||||
"videosource <cam|dummy> <call-id>",
|
||||
"videosource cam|dummy [<call_id>]",
|
||||
"Toggles camera source for specified call."
|
||||
"If no call is specified, the current call is taken.")
|
||||
{
|
||||
|
|
@ -150,8 +150,8 @@ void VideoSource::exec(Daemon* app, const string& args)
|
|||
|
||||
AutoVideo::AutoVideo():
|
||||
DaemonCommand("autovideo",
|
||||
"autovideo <on|off>",
|
||||
"Enables/disables automatic video setup when a call is issued")
|
||||
"autovideo on|off",
|
||||
"Enables/disables automatic video setup when a call is issued.")
|
||||
{
|
||||
addExample(new DaemonCommandExample("autovideo on",
|
||||
"Status: Ok\n\n"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue