2a8fd711 by Manish Mihsra

Added Master's Pami and Updated Code as Per Blind Transfer

1 parent 5435bb9e
Showing 44 changed files with 6749 additions and 67 deletions
......@@ -20,6 +20,7 @@ use PAMI\Message\Event\UnknownEvent;
use PAMI\Message\Event\DialBeginEvent;
use PAMI\Message\Event\DialEndEvent;
use PAMI\Message\Event\BlindTransferEvent;
use PAMI\Message\Event\AttendedTransferEvent;
use PAMI\Message\Action\AGIAction;
use PAMI\Message\Action\SIPNotifyAction;
......@@ -33,6 +34,8 @@ use PAMI\Message\Action\RedirectAction;
use PAMI\Message\Action\ConfbridgeMuteAction;
use PAMI\Message\Action\ConfbridgeUnmuteAction;
use PAMI\Message\Action\ActionMessage;
use PAMI\Message\Action\AttendedTransferAction;
use PAMI\Message\Action\BlindTransferAction;
use App\Models\Sipid;
use App\Models\User;
......@@ -782,7 +785,7 @@ class KPAMIListen implements IEventListener
$duniqueid=$event->getKey("DestUniqueid");
$dialstatus=$event->getKey("DialStatus");
Log::info($accountcode);
if($accountcode!="")
{
//echo "$accountcode:Unknown : $eventname $channelstate:$channelstatedesc $uniqueid $exten:$priority $channel\n";
......@@ -819,7 +822,7 @@ class KPAMIListen implements IEventListener
$dialline=Dialline::find($crmcall->dialline_id);
if($dialline)
{
$dialline->channel=$dchannel;
$dialline->channel=$channel;
$dialline->save();
}
......@@ -887,10 +890,10 @@ class KPAMIListen implements IEventListener
$dialline=Dialline::find($crmcall->dialline_id);
if($dialline && $dialstatus=="ANSWER")
{
$tsip=Sipid::find($crmcall->sipid_id);
// $tsip=Sipid::find($crmcall->sipid_id);
$newqueue=new Kqueue();
$newqueue->channelRedirectToExten($tsip->server,$dchannel,"1004".$tsip->id,"confTransfer","1");
// $newqueue=new Kqueue();
// $newqueue->channelRedirectToExten($tsip->server,$dchannel,"1004".$tsip->id."|".$dialline->channel,"confTransfer","1");
$dialline->channel=$dchannel;
$dialline->uniqueid=$uniqueid;
......@@ -914,6 +917,11 @@ class KPAMIListen implements IEventListener
Log::info("BlindTransferEvent");
}
private function AttendedTransferEvent(EventMessage $event)
{
Log::info(var_export($event));
}
private function UnknownEvent(EventMessage $event)
{
$eventname=$event->getKey("Event");
......@@ -1758,6 +1766,11 @@ if($crmcall->did=='46130234'){
$redirect=new RedirectAction($data['fromext'], $data['toext'], $data['context'], 1);
$res=$this->_client->send($redirect);
}
else if($tqueue->key=="transfer")
{
$blindtransferaction=new BlindTransferAction($data['channel'],$data['exten'],$data['context']);
$res=$this->_client->send($blindtransferaction);
}
$tqueue->delete();
}
......
......@@ -78,18 +78,24 @@ class Kqueue extends Model{
if($server != '')
{
$odata=array();$odata['VARS']=array();
$odata['fromext']="Local/1000".$sipid->id."@kstychDialer";
/*$odata['fromext']="Local/1000".$sipid->id."@kstychDialer";
$odata['context']="initiateTransfer";
$odata['callerid']=$channel;
$odata['toext']="1003".$callnumber;
$odata['account']='m|t|'.$crmcall->id;
$odata['VARS']['dialstr']=$dialstr;
$odata['VARS']['chnl']=$channel;
$odata['VARS']['callnumber']=$callnumber;
$odata['VARS']['callnumber']=$callnumber;*/
$odata['channel']=$channel;
$odata['exten']="1003".$callnumber;
$odata['context']="initiateTransfer";
$odata['priority']=1;
//originate conf
$this->type="SIP_".$server;
$this->key="originate";
$this->key="transfer";
$this->status="New";
$this->data=json_encode($odata);
$this->save();
......
......@@ -114,8 +114,19 @@ can still catch them. If you catch one of these, please report it!
* AGIExec
* AsyncAGI
* Bridge
* BridgeInfoChannel
* BridgeInfoComplete
* CEL
* ChannelUpdate
* ConfbridgeEnd
* ConfbridgeJoin
* ConfbridgeLeave
* ConfbridgeList
* ConfbridgeListComplete
* ConfbridgeMute
* ConfbridgeStart
* ConfbridgeTalking
* ConfbridgeUnmute
* CoreShowChannel
* CoreShowChannelComplete
* DAHDIShowChannel
......@@ -192,8 +203,10 @@ can still catch them. If you catch one of these, please report it!
* AgentLogoff
* Atxfer (asterisk 1.8?)
* Bridge
* BridgeInfo
* ChangeMonitor
* Command
* ConfbridgeList
* ConfbridgeMute
* ConfbridgeUnmute
* CoreSettings
......
......@@ -25,7 +25,7 @@
</target>
<target name="cpd">
<exec command="vendor/bin/phpcpd --fuzzy src"
<exec command="vendor/bin/phpcpd --fuzzy src --exclude PAMI/Message/Event"
checkreturn="true"
passthru="true"/>
</target>
......
PAMI\Message\Action\BridgeInfoAction
===============
Returns detailed information about a bridge and the channels in it.
PHP Version 5
* Class name: BridgeInfoAction
* Namespace: PAMI\Message\Action
* Parent class: [PAMI\Message\Action\ActionMessage](PAMI-Message-Action-ActionMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setActionID
void PAMI\Message\Action\ActionMessage::setActionID($actionID)
Sets Action ID.
The ActionID can be at most 69 characters long, according to
[Asterisk Issue 14847](https://issues.asterisk.org/jira/browse/14847).
Therefore we'll throw an exception when the ActionID is too long.
* Visibility: **public**
* This method is defined by [PAMI\Message\Action\ActionMessage](PAMI-Message-Action-ActionMessage.md)
#### Arguments
* $actionID **mixed** - &lt;p&gt;The Action ID to have this action known by&lt;/p&gt;
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
PAMI\Message\Action\ConfbridgeListAction
===============
Lists all users in a particular ConfBridge conference.
PHP Version 5
* Class name: ConfbridgeListAction
* Namespace: PAMI\Message\Action
* Parent class: [PAMI\Message\Action\ActionMessage](PAMI-Message-Action-ActionMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setActionID
void PAMI\Message\Action\ActionMessage::setActionID($actionID)
Sets Action ID.
The ActionID can be at most 69 characters long, according to
[Asterisk Issue 14847](https://issues.asterisk.org/jira/browse/14847).
Therefore we'll throw an exception when the ActionID is too long.
* Visibility: **public**
* This method is defined by [PAMI\Message\Action\ActionMessage](PAMI-Message-Action-ActionMessage.md)
#### Arguments
* $actionID **mixed** - &lt;p&gt;The Action ID to have this action known by&lt;/p&gt;
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
PAMI\Message\Event\BridgeInfoChannelEvent
===============
Event triggered when an action BridgeInfo is issued.
PHP Version 5
* Class name: BridgeInfoChannelEvent
* Namespace: PAMI\Message\Event
* Parent class: [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $rawContent
protected string $rawContent
Holds original message.
* Visibility: **protected**
### $channelVariables
protected array<mixed,string> $channelVariables
Metadata. Specific channel variables.
* Visibility: **protected**
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### getChannel
string PAMI\Message\Event\BridgeInfoChannelEvent::getChannel()
Returns key: 'Channel'.
* Visibility: **public**
### getChannelState
string PAMI\Message\Event\BridgeInfoChannelEvent::getChannelState()
Returns key: 'ChannelState'.
* Visibility: **public**
### getChannelStateDesc
string PAMI\Message\Event\BridgeInfoChannelEvent::getChannelStateDesc()
Returns key: 'ChannelStateDesc'.
* Visibility: **public**
### getCallerIDNum
string PAMI\Message\Event\BridgeInfoChannelEvent::getCallerIDNum()
Returns key: 'CallerIDNum'.
* Visibility: **public**
### getCallerIDName
string PAMI\Message\Event\BridgeInfoChannelEvent::getCallerIDName()
Returns key: 'CallerIDName'.
* Visibility: **public**
### getConnectedLineNum
string PAMI\Message\Event\BridgeInfoChannelEvent::getConnectedLineNum()
Returns key: 'ConnectedLineNum'.
* Visibility: **public**
### getConnectedLineName
string PAMI\Message\Event\BridgeInfoChannelEvent::getConnectedLineName()
Returns key: 'ConnectedLineName'.
* Visibility: **public**
### getAccountCode
string PAMI\Message\Event\BridgeInfoChannelEvent::getAccountCode()
Returns key: 'AccountCode'.
* Visibility: **public**
### getContext
string PAMI\Message\Event\BridgeInfoChannelEvent::getContext()
Returns key: 'Context'.
* Visibility: **public**
### getExten
string PAMI\Message\Event\BridgeInfoChannelEvent::getExten()
Returns key: 'Exten'.
* Visibility: **public**
### getPriority
string PAMI\Message\Event\BridgeInfoChannelEvent::getPriority()
Returns key: 'Priority'.
* Visibility: **public**
### getUniqueid
string PAMI\Message\Event\BridgeInfoChannelEvent::getUniqueid()
Returns key: 'Uniqueid'.
* Visibility: **public**
### getLinkedid
string PAMI\Message\Event\BridgeInfoChannelEvent::getLinkedid()
Returns key: 'Linkedid'.
* Visibility: **public**
### getName
string PAMI\Message\Event\EventMessage::getName()
Returns key 'Event'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getEventList
string PAMI\Message\IncomingMessage::getEventList()
Returns key 'EventList'. In respones, this will surely be a "start". In
events, should be a "complete".
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getRawContent
string PAMI\Message\IncomingMessage::getRawContent()
Returns the original message content without parsing.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getAllChannelVariables
array PAMI\Message\IncomingMessage::getAllChannelVariables()
Returns the channel variables for all reported channels.
https://github.com/marcelog/PAMI/issues/85
The channel names will be lowercased.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getChannelVariables
array PAMI\Message\IncomingMessage::getChannelVariables(string $channel)
Returns the channel variables for the given channel.
https://github.com/marcelog/PAMI/issues/85
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
#### Arguments
* $channel **string** - &lt;p&gt;Channel name. If not given, will return variables
for the &quot;current&quot; channel.&lt;/p&gt;
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
PAMI\Message\Event\BridgeInfoCompleteEvent
===============
Event triggered for the end of the list when an action BridgeInfo is issued.
PHP Version 5
* Class name: BridgeInfoCompleteEvent
* Namespace: PAMI\Message\Event
* Parent class: [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $rawContent
protected string $rawContent
Holds original message.
* Visibility: **protected**
### $channelVariables
protected array<mixed,string> $channelVariables
Metadata. Specific channel variables.
* Visibility: **protected**
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### getBridgeUniqueid
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeUniqueid()
Returns key: 'BridgeUniqueid'.
* Visibility: **public**
### getBridgeType
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeType()
Returns key: 'BridgeType'.
* Visibility: **public**
### getBridgeTechnology
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeTechnology()
Returns key: 'BridgeTechnology'.
* Visibility: **public**
### getBridgeCreator
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeCreator()
Returns key: 'BridgeCreator'.
* Visibility: **public**
### getBridgeName
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeName()
Returns key: 'BridgeName'.
* Visibility: **public**
### getBridgeNumChannels
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeNumChannels()
Returns key: 'BridgeNumChannels'.
* Visibility: **public**
### getBridgeVideoSourceMode
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeVideoSourceMode()
Returns key: 'BridgeVideoSourceMode'.
* Visibility: **public**
### getBridgeVideoSource
string PAMI\Message\Event\BridgeInfoCompleteEvent::getBridgeVideoSource()
Returns key: 'BridgeVideoSource'.
* Visibility: **public**
### getName
string PAMI\Message\Event\EventMessage::getName()
Returns key 'Event'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getEventList
string PAMI\Message\IncomingMessage::getEventList()
Returns key 'EventList'. In respones, this will surely be a "start". In
events, should be a "complete".
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getRawContent
string PAMI\Message\IncomingMessage::getRawContent()
Returns the original message content without parsing.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getAllChannelVariables
array PAMI\Message\IncomingMessage::getAllChannelVariables()
Returns the channel variables for all reported channels.
https://github.com/marcelog/PAMI/issues/85
The channel names will be lowercased.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getChannelVariables
array PAMI\Message\IncomingMessage::getChannelVariables(string $channel)
Returns the channel variables for the given channel.
https://github.com/marcelog/PAMI/issues/85
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
#### Arguments
* $channel **string** - &lt;p&gt;Channel name. If not given, will return variables
for the &quot;current&quot; channel.&lt;/p&gt;
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
PAMI\Message\Event\ConfbridgeListCompleteEvent
===============
Event triggered for the end of the list when an action ConfbridgeList is issued.
PHP Version 5
* Class name: ConfbridgeListCompleteEvent
* Namespace: PAMI\Message\Event
* Parent class: [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $rawContent
protected string $rawContent
Holds original message.
* Visibility: **protected**
### $channelVariables
protected array<mixed,string> $channelVariables
Metadata. Specific channel variables.
* Visibility: **protected**
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### getListItems
string PAMI\Message\Event\ConfbridgeListCompleteEvent::getListItems()
Returns key: 'ListItems'.
* Visibility: **public**
### getName
string PAMI\Message\Event\EventMessage::getName()
Returns key 'Event'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getEventList
string PAMI\Message\IncomingMessage::getEventList()
Returns key 'EventList'. In respones, this will surely be a "start". In
events, should be a "complete".
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getRawContent
string PAMI\Message\IncomingMessage::getRawContent()
Returns the original message content without parsing.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getAllChannelVariables
array PAMI\Message\IncomingMessage::getAllChannelVariables()
Returns the channel variables for all reported channels.
https://github.com/marcelog/PAMI/issues/85
The channel names will be lowercased.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getChannelVariables
array PAMI\Message\IncomingMessage::getChannelVariables(string $channel)
Returns the channel variables for the given channel.
https://github.com/marcelog/PAMI/issues/85
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
#### Arguments
* $channel **string** - &lt;p&gt;Channel name. If not given, will return variables
for the &quot;current&quot; channel.&lt;/p&gt;
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
PAMI\Message\Event\ConfbridgeListEvent
===============
Event triggered when an action ConfbridgeList is issued.
PHP Version 5
* Class name: ConfbridgeListEvent
* Namespace: PAMI\Message\Event
* Parent class: [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
Constants
----------
### EOL
const EOL = "\r\n"
### EOM
const EOM = "\r\n\r\n"
Properties
----------
### $rawContent
protected string $rawContent
Holds original message.
* Visibility: **protected**
### $channelVariables
protected array<mixed,string> $channelVariables
Metadata. Specific channel variables.
* Visibility: **protected**
### $lines
protected array<mixed,string> $lines
Message content, line by line. This is what it gets sent
or received literally.
* Visibility: **protected**
### $variables
protected array<mixed,string> $variables
Metadata. Message variables (key/value).
* Visibility: **protected**
### $keys
protected array<mixed,string> $keys
Metadata. Message "keys" i.e: Action: login
* Visibility: **protected**
### $createdDate
protected integer $createdDate
Created date (unix timestamp).
* Visibility: **protected**
Methods
-------
### getConference
string PAMI\Message\Event\ConfbridgeListEvent::getConference()
Returns key: 'Conference'.
* Visibility: **public**
### getChannel
string PAMI\Message\Event\ConfbridgeListEvent::getChannel()
Returns key: 'Channel'.
* Visibility: **public**
### getCallerIDNum
string PAMI\Message\Event\ConfbridgeListEvent::getCallerIDNum()
Returns key: 'CallerIDNum'.
* Visibility: **public**
### getCallerIDName
string PAMI\Message\Event\ConfbridgeListEvent::getCallerIDName()
Returns key: 'CallerIDName'.
* Visibility: **public**
### getMarkedUser
string PAMI\Message\Event\ConfbridgeListEvent::getMarkedUser()
Returns key: 'MarkedUser'.
* Visibility: **public**
### getWaitMarked
string PAMI\Message\Event\ConfbridgeListEvent::getWaitMarked()
Returns key: 'WaitMarked'.
* Visibility: **public**
### getEndMarked
string PAMI\Message\Event\ConfbridgeListEvent::getEndMarked()
Returns key: 'EndMarked'.
* Visibility: **public**
### getWaiting
string PAMI\Message\Event\ConfbridgeListEvent::getWaiting()
Returns key: 'Waiting'.
* Visibility: **public**
### getMuted
string PAMI\Message\Event\ConfbridgeListEvent::getMuted()
Returns key: 'Muted'.
* Visibility: **public**
### getAnsweredTime
string PAMI\Message\Event\ConfbridgeListEvent::getAnsweredTime()
Returns key: 'AnsweredTime'.
* Visibility: **public**
### getAdmin
string PAMI\Message\Event\ConfbridgeListEvent::getAdmin()
Returns key: 'Admin'.
* Visibility: **public**
### getName
string PAMI\Message\Event\EventMessage::getName()
Returns key 'Event'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Event\EventMessage](PAMI-Message-Event-EventMessage.md)
### __sleep
array<mixed,string> PAMI\Message\Message::__sleep()
Serialize function.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getEventList
string PAMI\Message\IncomingMessage::getEventList()
Returns key 'EventList'. In respones, this will surely be a "start". In
events, should be a "complete".
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getRawContent
string PAMI\Message\IncomingMessage::getRawContent()
Returns the original message content without parsing.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getAllChannelVariables
array PAMI\Message\IncomingMessage::getAllChannelVariables()
Returns the channel variables for all reported channels.
https://github.com/marcelog/PAMI/issues/85
The channel names will be lowercased.
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
### getChannelVariables
array PAMI\Message\IncomingMessage::getChannelVariables(string $channel)
Returns the channel variables for the given channel.
https://github.com/marcelog/PAMI/issues/85
* Visibility: **public**
* This method is defined by [PAMI\Message\IncomingMessage](PAMI-Message-IncomingMessage.md)
#### Arguments
* $channel **string** - &lt;p&gt;Channel name. If not given, will return variables
for the &quot;current&quot; channel.&lt;/p&gt;
### __construct
void PAMI\Message\Message::__construct()
Constructor.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getCreatedDate
integer PAMI\Message\Message::getCreatedDate()
Returns created date.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### setVariable
void PAMI\Message\Message::setVariable(string $key, string $value)
Adds a variable to this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
* $value **string** - &lt;p&gt;Variable value.&lt;/p&gt;
### getVariable
string PAMI\Message\Message::getVariable(string $key)
Returns a variable by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
### setKey
void PAMI\Message\Message::setKey(string $key, string $value)
Adds a variable to this message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
* $value **string** - &lt;p&gt;Key value.&lt;/p&gt;
### getKey
string PAMI\Message\Message::getKey(string $key)
Returns a key by name.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string** - &lt;p&gt;Key name (i.e: Action).&lt;/p&gt;
### getKeys
array<mixed,string> PAMI\Message\Message::getKeys()
Returns all keys for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getVariables
array<mixed,string> PAMI\Message\Message::getVariables()
Returns all variabels for this message.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### finishMessage
string PAMI\Message\Message::finishMessage($message)
Returns the end of message token appended to the end of a given message.
* Visibility: **protected**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $message **mixed**
### serializeVariable
string PAMI\Message\Message::serializeVariable(string $key, string $value)
Returns the string representation for an ami action variable.
* Visibility: **private**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
#### Arguments
* $key **string**
* $value **string**
### serialize
string PAMI\Message\Message::serialize()
Gives a string representation for this message, ready to be sent to
ami.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
### getActionID
string PAMI\Message\Message::getActionID()
Returns key: 'ActionID'.
* Visibility: **public**
* This method is defined by [PAMI\Message\Message](PAMI-Message-Message.md)
......@@ -34,9 +34,7 @@ use PAMI\Message\OutgoingMessage;
use PAMI\Message\Message;
use PAMI\Message\IncomingMessage;
use PAMI\Message\Action\LoginAction;
use PAMI\Message\Action\LogoffAction;
use PAMI\Message\Response\ResponseMessage;
use PAMI\Message\Event\EventMessage;
use PAMI\Message\Event\Factory\Impl\EventFactoryImpl;
use PAMI\Listener\IEventListener;
use PAMI\Client\Exception\ClientException;
......@@ -60,7 +58,7 @@ class ClientImpl implements IClient
{
/**
* PSR-3 logger.
* @var Logger
* @var LoggerInterface
*/
private $logger;
......@@ -151,6 +149,12 @@ class ClientImpl implements IClient
private $lastActionId;
/**
* Event mask to apply on login action.
* @var string|null
*/
private $eventMask;
/**
* Opens a tcp connection to ami.
*
* @throws \PAMI\Client\Exception\ClientException
......@@ -173,7 +177,7 @@ class ClientImpl implements IClient
if ($this->socket === false) {
throw new ClientException('Error connecting to ami: ' . $errstr);
}
$msg = new LoginAction($this->user, $this->pass);
$msg = new LoginAction($this->user, $this->pass, $this->eventMask);
$asteriskId = @stream_get_line($this->socket, 1024, Message::EOL);
if (strstr($asteriskId, 'Asterisk') === false) {
throw new ClientException(
......@@ -434,7 +438,7 @@ class ClientImpl implements IClient
/**
* Sets the logger implementation.
*
* @param Psr\Log\LoggerInterface $logger The PSR3-Logger
* @param LoggerInterface $logger The PSR3-Logger
*
* @return void
*/
......@@ -453,12 +457,13 @@ class ClientImpl implements IClient
{
$this->logger = new NullLogger;
$this->host = $options['host'];
$this->port = intval($options['port']);
$this->port = (int) $options['port'];
$this->user = $options['username'];
$this->pass = $options['secret'];
$this->cTimeout = $options['connect_timeout'];
$this->rTimeout = $options['read_timeout'];
$this->scheme = isset($options['scheme']) ? $options['scheme'] : 'tcp://';
$this->eventMask = isset($options['event_mask']) ? $options['event_mask'] : null;
$this->eventListeners = array();
$this->eventFactory = new EventFactoryImpl();
$this->incomingQueue = array();
......
<?php
/**
* BlindTransfer action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* BlindTransfer action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class BlindTransferAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $channel Transferer's channel.
* @param string $extension Extension to transfer to.
* @param string $context Context to transfer to.
*/
public function __construct($channel, $extension, $context)
{
parent::__construct('BlindTransfer');
$this->setKey('Channel', $channel);
$this->setKey('Exten', $extension);
$this->setKey('Context', $context);
}
}
<?php
/**
* Returns detailed information about a bridge and the channels in it.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* Returns detailed information about a bridge and the channels in it.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class BridgeInfoAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $bridgeUniqueid The unique ID of the bridge about which to retrieve information.
*
* @return void
*/
public function __construct($bridgeUniqueid)
{
parent::__construct('BridgeInfo');
$this->setKey('BridgeUniqueid', $bridgeUniqueid);
}
}
<?php
/**
* Challenge action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* Challenge action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ChallengeAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $authType Auth type
*/
public function __construct($authType = 'MD5')
{
parent::__construct('Challenge');
$this->setKey('AuthType', $authType);
}
}
......
<?php
/**
* ConfbridgeList action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* Lists all users in a particular ConfBridge conference.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeListAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $conference Conference on which to act.
*
* @return void
*/
public function __construct($conference)
{
parent::__construct('ConfbridgeList');
$this->setKey('Conference', $conference);
}
}
<?php
/**
* DAHDITransfer action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* DAHDITransfer action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class DAHDITransferAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $channel DAHDIChannel
*/
public function __construct($channel)
{
parent::__construct('DAHDITransfer');
$this->setKey('DAHDIChannel', $channel);
}
}
......
......@@ -47,12 +47,17 @@ class HangupAction extends ActionMessage
* Constructor.
*
* @param string $channel Channel to hangup.
* @param int $cause Hangup cause.
*
* @return void
*/
public function __construct($channel)
public function __construct($channel, $cause = null)
{
parent::__construct('Hangup');
$this->setKey('Channel', $channel);
if (null !== $cause) {
$this->setKey('Cause', $cause);
}
}
}
......
......@@ -46,15 +46,20 @@ class LoginAction extends ActionMessage
/**
* Constructor.
*
* @param string $user AMI username.
* @param string $user AMI username.
* @param string $password AMI password.
* @param string|null $eventMask
*
* @return void
*/
public function __construct($user, $password)
public function __construct($user, $password, $eventMask = null)
{
parent::__construct('Login');
$this->setKey('Username', $user);
$this->setKey('Secret', $password);
if (null !== $eventMask) {
$this->setKey('Events', $eventMask);
}
}
}
......
<?php
/**
* MixMonitorMute action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* MixMonitorMute action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class MixMonitorMuteAction extends ActionMessage
{
const DIRECTION_READ = 'read';
const DIRECTION_WRITE = 'write';
const DIRECTION_BOTH = 'both';
/**
* Sets state key.
*
* @param bool $state Mute state
*
* @return void
*/
public function setState($state)
{
$this->setKey('State', $state ? 1 : 0);
}
/**
* Sets state key.
*
* @param string $direction Which part of the recording to mute:
* read, write or both (from channel, to channel or both channels).
*
* @return void
*/
public function setDirection($direction)
{
$this->setKey('Direction', $direction);
}
/**
* Constructor.
*
* @param string $channel Channel on which to act.
* @param bool $state Turn mute on or off
* @param string $direction Which part of the recording to mute:
* read, write or both (from channel, to channel or both channels).
*/
public function __construct($channel, $state = true, $direction = 'both')
{
parent::__construct('MixMonitorMute');
$this->setKey('Channel', $channel);
$this->setState($state);
$this->setDirection($direction);
}
}
<?php
/**
* UserEvent action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* UserEvent action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class UserEventAction extends ActionMessage
{
/**
* Constructor.
*
* @param string $userEvent UserEvent
* @param array $headers
*/
public function __construct($userEvent, array $headers = [])
{
parent::__construct('UserEvent');
$this->setKey('UserEvent', $userEvent);
foreach ($headers as $key => $value) {
$this->setKey((string)$key, (string)$value);
}
}
}
......
......@@ -150,8 +150,8 @@ class VGSMSMSTxAction extends ActionMessage
public function setConcatTotalMsg($totalmsg)
{
$this->setKey('X-SMS-Concatenate-Total-Messages', $totalmsg);
}
/**
* Sets Account key.
*
......
<?php
/**
* WaitEvent action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Action;
/**
* WaitEvent action message.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Action
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class WaitEventAction extends ActionMessage
{
/**
* Constructor.
*
* @param int $timeout Timeout in seconds
*/
public function __construct($timeout)
{
parent::__construct('WaitEvent');
$this->setKey('Timeout', (int)$timeout);
}
}
......
<?php
/**
* Event triggered when an action BridgeInfo is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when an action BridgeInfo is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class BridgeInfoChannelEvent extends EventMessage
{
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
}
<?php
/**
* Event triggered for the end of the list when an action BridgeInfo is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered for the end of the list when an action BridgeInfo is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class BridgeInfoCompleteEvent extends EventMessage
{
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'BridgeVideoSourceMode'.
*
* @return string
*/
public function getBridgeVideoSourceMode()
{
return $this->getKey('BridgeVideoSourceMode');
}
/**
* Returns key: 'BridgeVideoSource'.
*
* @return string
*/
public function getBridgeVideoSource()
{
return $this->getKey('BridgeVideoSource');
}
}
<?php
/**
* Event triggered when a confbridge is destroyed.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a confbridge is destroyed.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeEndEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
}
<?php
/**
* Event triggered when a channel enters a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a channel enters a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeJoinEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
<?php
/**
* Event triggered when a channel leaves a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a channel leaves a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeLeaveEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
<?php
/**
* Event triggered for the end of the list when an action ConfbridgeList is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
use PAMI\Message\Event\EventMessage;
/**
* Event triggered for the end of the list when an action ConfbridgeList is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeListCompleteEvent extends EventMessage
{
/**
* Returns key: 'ListItems'.
*
* @return string
*/
public function getListItems()
{
return $this->getKey('ListItems');
}
}
<?php
/**
* Event triggered when an action ConfbridgeList is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when an action ConfbridgeList is issued.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Matt Styles <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeListEvent extends EventMessage
{
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'MarkedUser'.
*
* @return string
*/
public function getMarkedUser()
{
return $this->getKey('MarkedUser');
}
/**
* Returns key: 'WaitMarked'.
*
* @return string
*/
public function getWaitMarked()
{
return $this->getKey('WaitMarked');
}
/**
* Returns key: 'EndMarked'.
*
* @return string
*/
public function getEndMarked()
{
return $this->getKey('EndMarked');
}
/**
* Returns key: 'Waiting'.
*
* @return string
*/
public function getWaiting()
{
return $this->getKey('Waiting');
}
/**
* Returns key: 'Muted'.
*
* @return string
*/
public function getMuted()
{
return $this->getKey('Muted');
}
/**
* Returns key: 'AnsweredTime'.
*
* @return string
*/
public function getAnsweredTime()
{
return $this->getKey('AnsweredTime');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
<?php
/**
* Event triggered when a channel is muted in a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a channel is muted in a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeMuteEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
<?php
/**
* Event triggered when a confbridge is created.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a confbridge is created.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeStartEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
}
<?php
/**
* Event triggered when a channel in a Confbridge begins or ends talking
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a channel in a Confbridge begins or ends talking
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeTalkingEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
/**
* Returns key: 'TalkingStatus'.
*
* @return string
*/
public function getTalkingStatus()
{
return $this->getKey('TalkingStatus');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
<?php
/**
* Event triggered when a channel is unmuted in a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @version SVN: $Id$
* @link http://marcelog.github.com/PAMI/
*
* Copyright 2011 Marcelo Gornstein <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
namespace PAMI\Message\Event;
/**
* Event triggered when a channel is unmuted in a confbridge.
*
* PHP Version 5
*
* @category Pami
* @package Message
* @subpackage Event
* @author Marcelo Gornstein <[email protected]>
* @license http://marcelog.github.com/PAMI/ Apache License 2.0
* @link http://marcelog.github.com/PAMI/
*/
class ConfbridgeUnmuteEvent extends EventMessage
{
/**
* Returns key: 'Privilege'.
*
* @return string
*/
public function getPrivilege()
{
return $this->getKey('Privilege');
}
/**
* Returns key: 'Conference'.
*
* @return string
*/
public function getConference()
{
return $this->getKey('Conference');
}
/**
* Returns key: 'BridgeUniqueid'.
*
* @return string
*/
public function getBridgeUniqueid()
{
return $this->getKey('BridgeUniqueid');
}
/**
* Returns key: 'BridgeType'.
*
* @return string
*/
public function getBridgeType()
{
return $this->getKey('BridgeType');
}
/**
* Returns key: 'BridgeTechnology'.
*
* @return string
*/
public function getBridgeTechnology()
{
return $this->getKey('BridgeTechnology');
}
/**
* Returns key: 'BridgeCreator'.
*
* @return string
*/
public function getBridgeCreator()
{
return $this->getKey('BridgeCreator');
}
/**
* Returns key: 'BridgeName'.
*
* @return string
*/
public function getBridgeName()
{
return $this->getKey('BridgeName');
}
/**
* Returns key: 'BridgeNumChannels'.
*
* @return string
*/
public function getBridgeNumChannels()
{
return $this->getKey('BridgeNumChannels');
}
/**
* Returns key: 'Channel'.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
}
/**
* Returns key: 'ChannelState'.
*
* @return string
*/
public function getChannelState()
{
return $this->getKey('ChannelState');
}
/**
* Returns key: 'ChannelStateDesc'.
*
* @return string
*/
public function getChannelStateDesc()
{
return $this->getKey('ChannelStateDesc');
}
/**
* Returns key: 'CallerIDNum'.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
}
/**
* Returns key: 'CallerIDName'.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
}
/**
* Returns key: 'ConnectedLineNum'.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ConnectedLineName'.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'AccountCode'.
*
* @return string
*/
public function getAccountCode()
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Context'.
*
* @return string
*/
public function getContext()
{
return $this->getKey('Context');
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
/**
* Returns key: 'Uniqueid'.
*
* @return string
*/
public function getUniqueid()
{
return $this->getKey('Uniqueid');
}
/**
* Returns key: 'Linkedid'.
*
* @return string
*/
public function getLinkedid()
{
return $this->getKey('Linkedid');
}
/**
* Returns key: 'Admin'.
*
* @return string
*/
public function getAdmin()
{
return $this->getKey('Admin');
}
}
......@@ -302,4 +302,14 @@ class DialBeginEvent extends EventMessage
{
return $this->getKey('DialStatus');
}
/**
* Returns key: 'DialString'.
*
* @return string
*/
public function getDialString()
{
return $this->getKey('DialString');
}
}
......
......@@ -29,8 +29,6 @@
*/
namespace PAMI\Message\Event;
use PAMI\Message\Event\EventMessage;
/**
* Event triggered when a new extension is accessed.
*
......@@ -66,7 +64,8 @@ class NewextenEvent extends EventMessage
}
/**
* Returns key: 'Exten'.
* Returns key: 'Extension'.
* @deprecated Please use {@see getExten()}.
*
* @return string
*/
......@@ -76,6 +75,16 @@ class NewextenEvent extends EventMessage
}
/**
* Returns key: 'Exten'.
*
* @return string
*/
public function getExten()
{
return $this->getKey('Exten') ?: $this->getKey('Extension');
}
/**
* Returns key: 'Context'.
*
* @return string
......
......@@ -29,8 +29,6 @@
*/
namespace PAMI\Message\Event;
use PAMI\Message\Event\EventMessage;
/**
* Event triggered when a call is parked.
*
......@@ -77,81 +75,249 @@ class ParkedCallEvent extends EventMessage
/**
* Returns key: 'Timeout'.
* @deprecated Deprecated since Asterisk 12. {@use ParkingTimeout()}.
*
* @return string
*/
public function getTimeout()
{
return $this->getKey('Timeout');
return $this->getParkingTimeout();
}
/**
* Returns key: 'ConnectedLineNum'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeConnectedLineNum()}.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
return $this->getParkeeConnectedLineNum();
}
/**
* Returns key: 'ConnectedLineName'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeConnectedLineName()}.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
return $this->getParkeeConnectedLineName();
}
/**
* Returns key: 'Channel'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeChannel()}.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
return $this->getParkeeChannel();
}
/**
* Returns key: 'CallerIDNum'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeCallerIDNum()}.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
return $this->getParkeeCallerIDNum();
}
/**
* Returns key: 'CallerIDName'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeCallerIDName()}.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
return $this->getParkeeCallerIDName();
}
/**
* Returns key: 'UniqueID'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeUniqueid()}.
*
* @return string
*/
public function getUniqueID()
{
return $this->getKey('UniqueID');
return $this->getParkeeUniqueid();
}
/**
* Returns key: 'Exten'.
* @deprecated Deprecated since Asterisk 12. {@use getParkingSpace()}.
*
* @return string
*/
public function getExtension()
{
return $this->getKey('Exten');
return $this->getParkingSpace();
}
/**
* Returns key: 'ParkeeChannel'.
*
* @return string
*/
public function getParkeeChannel()
{
return $this->getKey('ParkeeChannel') ?: $this->getKey('Channel');
}
/**
* Returns key: 'ParkeeChannelState'.
*
* @return string
*/
public function getParkeeChannelState()
{
return $this->getKey('ParkeeChannelState');
}
/**
* Returns key: 'ParkeeChannelStateDesc'.
*
* @return string
*/
public function getParkeeChannelStateDesc()
{
return $this->getKey('ParkeeChannelStateDesc');
}
/**
* Returns key: 'ParkeeCallerIDNum'.
*
* @return string
*/
public function getParkeeCallerIDNum()
{
return $this->getKey('ParkeeCallerIDNum') ?: $this->getKey('CallerIDNum');
}
/**
* Returns key: 'ParkeeCallerIDName'.
*
* @return string
*/
public function getParkeeCallerIDName()
{
return $this->getKey('ParkeeCallerIDName') ?: $this->getKey('CallerIDName');
}
/**
* Returns key: 'ParkeeConnectedLineNum'.
*
* @return string
*/
public function getParkeeConnectedLineNum()
{
return $this->getKey('ParkeeConnectedLineNum') ?: $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ParkeeConnectedLineName'.
*
* @return string
*/
public function getParkeeConnectedLineName()
{
return $this->getKey('ParkeeConnectedLineName') ?: $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'ParkeeAccountCode'.
*
* @return string
*/
public function getParkeeAccountCode()
{
return $this->getKey('ParkeeAccountCode');
}
/**
* Returns key: 'ParkeeContext'.
*
* @return string
*/
public function getParkeeContext()
{
return $this->getKey('ParkeeContext');
}
/**
* Returns key: 'ParkeeExten'.
*
* @return string
*/
public function getParkeeExten()
{
return $this->getKey('ParkeeExten');
}
/**
* Returns key: 'ParkeePriority'.
*
* @return string
*/
public function getParkeePriority()
{
return $this->getKey('ParkeePriority');
}
/**
* Returns key: 'ParkeeUniqueid'.
*
* @return string
*/
public function getParkeeUniqueid()
{
return $this->getKey('ParkeeUniqueid') ?: $this->getKey('UniqueId');
}
/**
* Returns key: 'ParkerDialString'.
*
* @return string
*/
public function getParkerDialString()
{
return $this->getKey('ParkerDialString');
}
/**
* Returns key: 'ParkingSpace'.
*
* @return string
*/
public function getParkingSpace()
{
return $this->getKey('ParkingSpace') ?: $this->getKey('Exten');
}
/**
* Returns key: 'ParkingTimeout'.
*
* @return string
*/
public function getParkingTimeout()
{
return $this->getKey('ParkingTimeout') ?: $this->getKey('Timeout');
}
/**
* Returns key: 'ParkingDuration'.
*
* @return string
*/
public function getParkingDuration()
{
return $this->getKey('ParkingDuration');
}
}
......
......@@ -164,13 +164,13 @@ class QueueCallerAbandonEvent extends EventMessage
}
/**
* Returns key: 'Uniqueid'.
* Returns key: 'UniqueID'.
*
* @return string
*/
public function getUniqueid()
public function getUniqueID()
{
return $this->getKey('Uniqueid');
return $this->getKey('UniqueID');
}
/**
......
......@@ -192,4 +192,14 @@ class QueueCallerJoinEvent extends EventMessage
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
}
......
......@@ -192,4 +192,14 @@ class QueueCallerLeaveEvent extends EventMessage
{
return $this->getKey('AccountCode');
}
/**
* Returns key: 'Priority'.
*
* @return string
*/
public function getPriority()
{
return $this->getKey('Priority');
}
}
......
......@@ -29,8 +29,6 @@
*/
namespace PAMI\Message\Event;
use PAMI\Message\Event\EventMessage;
/**
* Event triggered when a call is unparked.
*
......@@ -67,81 +65,500 @@ class UnParkedCallEvent extends EventMessage
/**
* Returns key: 'From'.
* @deprecated Deprecated since Asterisk 12. {@use getRetrieverChannel()}.
*
* @return string
*/
public function getFrom()
{
return $this->getKey('From');
return $this->getRetrieverChannel();
}
/**
* Returns key: 'Timeout'.
* @deprecated Deprecated since Asterisk 12. {@use ParkingTimeout()}.
*
* @return string
*/
public function getTimeout()
{
return $this->getParkingTimeout();
}
/**
* Returns key: 'ConnectedLineNum'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeConnectedLineNum()}.
*
* @return string
*/
public function getConnectedLineNum()
{
return $this->getKey('ConnectedLineNum');
return $this->getParkeeConnectedLineNum();
}
/**
* Returns key: 'ConnectedLineName'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeConnectedLineName()}.
*
* @return string
*/
public function getConnectedLineName()
{
return $this->getKey('ConnectedLineName');
return $this->getParkeeConnectedLineName();
}
/**
* Returns key: 'Channel'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeChannel()}.
*
* @return string
*/
public function getChannel()
{
return $this->getKey('Channel');
return $this->getParkeeChannel();
}
/**
* Returns key: 'CallerIDNum'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeCallerIDNum()}.
*
* @return string
*/
public function getCallerIDNum()
{
return $this->getKey('CallerIDNum');
return $this->getParkeeCallerIDNum();
}
/**
* Returns key: 'CallerIDName'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeCallerIDName()}.
*
* @return string
*/
public function getCallerIDName()
{
return $this->getKey('CallerIDName');
return $this->getParkeeCallerIDName();
}
/**
* Returns key: 'UniqueID'.
* @deprecated Deprecated since Asterisk 12. {@use getParkeeUniqueid()}.
*
* @return string
*/
public function getUniqueID()
{
return $this->getKey('UniqueID');
return $this->getParkeeUniqueid();
}
/**
* Returns key: 'Exten'.
* @deprecated Deprecated since Asterisk 12. {@use getParkingSpace()}.
*
* @return string
*/
public function getExtension()
{
return $this->getKey('Exten');
return $this->getParkingSpace();
}
/**
* Returns key: 'ParkeeChannel'.
*
* @return string
*/
public function getParkeeChannel()
{
return $this->getKey('ParkeeChannel') ?: $this->getKey('Channel');
}
/**
* Returns key: 'ParkeeChannelState'.
*
* @return string
*/
public function getParkeeChannelState()
{
return $this->getKey('ParkeeChannelState');
}
/**
* Returns key: 'ParkeeChannelStateDesc'.
*
* @return string
*/
public function getParkeeChannelStateDesc()
{
return $this->getKey('ParkeeChannelStateDesc');
}
/**
* Returns key: 'ParkeeCallerIDNum'.
*
* @return string
*/
public function getParkeeCallerIDNum()
{
return $this->getKey('ParkeeCallerIDNum') ?: $this->getKey('CallerIDNum');
}
/**
* Returns key: 'ParkeeCallerIDName'.
*
* @return string
*/
public function getParkeeCallerIDName()
{
return $this->getKey('ParkeeCallerIDName') ?: $this->getKey('CallerIDName');
}
/**
* Returns key: 'ParkeeConnectedLineNum'.
*
* @return string
*/
public function getParkeeConnectedLineNum()
{
return $this->getKey('ParkeeConnectedLineNum') ?: $this->getKey('ConnectedLineNum');
}
/**
* Returns key: 'ParkeeConnectedLineName'.
*
* @return string
*/
public function getParkeeConnectedLineName()
{
return $this->getKey('ParkeeConnectedLineName') ?: $this->getKey('ConnectedLineName');
}
/**
* Returns key: 'ParkeeAccountCode'.
*
* @return string
*/
public function getParkeeAccountCode()
{
return $this->getKey('ParkeeAccountCode');
}
/**
* Returns key: 'ParkeeContext'.
*
* @return string
*/
public function getParkeeContext()
{
return $this->getKey('ParkeeContext');
}
/**
* Returns key: 'ParkeeExten'.
*
* @return string
*/
public function getParkeeExten()
{
return $this->getKey('ParkeeExten');
}
/**
* Returns key: 'ParkeePriority'.
*
* @return string
*/
public function getParkeePriority()
{
return $this->getKey('ParkeePriority');
}
/**
* Returns key: 'ParkeeUniqueid'.
*
* @return string
*/
public function getParkeeUniqueid()
{
return $this->getKey('ParkeeUniqueid') ?: $this->getKey('UniqueId');
}
/**
* Returns key: 'ParkerDialString'.
*
* @return string
*/
public function getParkerDialString()
{
return $this->getKey('ParkerDialString');
}
/**
* Returns key: 'ParkingSpace'.
*
* @return string
*/
public function getParkingSpace()
{
return $this->getKey('ParkingSpace') ?: $this->getKey('Exten');
}
/**
* Returns key: 'ParkingTimeout'.
*
* @return string
*/
public function getParkingTimeout()
{
return $this->getKey('ParkingTimeout') ?: $this->getKey('Timeout');
}
/**
* Returns key: 'ParkingDuration'.
*
* @return string
*/
public function getParkingDuration()
{
return $this->getKey('ParkingDuration');
}
/**
* Returns key: 'ParkerChannel'.
*
* @return string
*/
public function getParkerChannel()
{
return $this->getKey('ParkerChannel');
}
/**
* Returns key: 'ParkerChannelState'.
*
* @return string
*/
public function getParkerChannelState()
{
return $this->getKey('ParkerChannelState');
}
/**
* Returns key: 'ParkerChannelStateDesc'.
*
* @return string
*/
public function getParkerChannelStateDesc()
{
return $this->getKey('ParkerChannelStateDesc');
}
/**
* Returns key: 'ParkerCallerIDNum'.
*
* @return string
*/
public function getParkerCallerIDNum()
{
return $this->getKey('ParkerCallerIDNum');
}
/**
* Returns key: 'ParkerCallerIDName'.
*
* @return string
*/
public function getParkerCallerIDName()
{
return $this->getKey('ParkerCallerIDName');
}
/**
* Returns key: 'ParkerConnectedLineNum'.
*
* @return string
*/
public function getParkerConnectedLineNum()
{
return $this->getKey('ParkerConnectedLineNum');
}
/**
* Returns key: 'ParkerConnectedLineName'.
*
* @return string
*/
public function getParkerConnectedLineName()
{
return $this->getKey('ParkerConnectedLineName');
}
/**
* Returns key: 'ParkerAccountCode'.
*
* @return string
*/
public function getParkerAccountCode()
{
return $this->getKey('ParkerAccountCode');
}
/**
* Returns key: 'ParkerContext'.
*
* @return string
*/
public function getParkerContext()
{
return $this->getKey('ParkerContext');
}
/**
* Returns key: 'ParkerExten'.
*
* @return string
*/
public function getParkerExten()
{
return $this->getKey('ParkerExten');
}
/**
* Returns key: 'ParkerPriority'.
*
* @return string
*/
public function getParkerPriority()
{
return $this->getKey('ParkerPriority');
}
/**
* Returns key: 'ParkerUniqueid'.
*
* @return string
*/
public function getParkerUniqueid()
{
return $this->getKey('ParkerUniqueid');
}
/**
* Returns key: 'RetrieverChannel'.
*
* @return string
*/
public function getRetrieverChannel()
{
return $this->getKey('RetrieverChannel') ?: $this->getKey('From');
}
/**
* Returns key: 'RetrieverChannelState'.
*
* @return string
*/
public function getRetrieverChannelState()
{
return $this->getKey('RetrieverChannelState');
}
/**
* Returns key: 'RetrieverChannelStateDesc'.
*
* @return string
*/
public function getRetrieverChannelStateDesc()
{
return $this->getKey('RetrieverChannelStateDesc');
}
/**
* Returns key: 'RetrieverCallerIDNum'.
*
* @return string
*/
public function getRetrieverCallerIDNum()
{
return $this->getKey('RetrieverCallerIDNum');
}
/**
* Returns key: 'RetrieverCallerIDName'.
*
* @return string
*/
public function getRetrieverCallerIDName()
{
return $this->getKey('RetrieverCallerIDName');
}
/**
* Returns key: 'RetrieverConnectedLineNum'.
*
* @return string
*/
public function getRetrieverConnectedLineNum()
{
return $this->getKey('RetrieverConnectedLineNum');
}
/**
* Returns key: 'RetrieverConnectedLineName'.
*
* @return string
*/
public function getRetrieverConnectedLineName()
{
return $this->getKey('RetrieverConnectedLineName');
}
/**
* Returns key: 'RetrieverAccountCode'.
*
* @return string
*/
public function getRetrieverAccountCode()
{
return $this->getKey('RetrieverAccountCode');
}
/**
* Returns key: 'RetrieverContext'.
*
* @return string
*/
public function getRetrieverContext()
{
return $this->getKey('RetrieverContext');
}
/**
* Returns key: 'RetrieverExten'.
*
* @return string
*/
public function getRetrieverExten()
{
return $this->getKey('RetrieverExten');
}
/**
* Returns key: 'RetrieverPriority'.
*
* @return string
*/
public function getRetrieverPriority()
{
return $this->getKey('RetrieverPriority');
}
/**
* Returns key: 'RetrieverUniqueid'.
*
* @return string
*/
public function getRetrieverUniqueid()
{
return $this->getKey('RetrieverUniqueid');
}
}
......
......@@ -108,7 +108,6 @@ abstract class Message
*/
public function setVariable($key, $value)
{
$key = strtolower($key);
$this->variables[$key] = $value;
}
......@@ -121,7 +120,6 @@ abstract class Message
*/
public function getVariable($key)
{
$key = strtolower($key);
if (!isset($this->variables[$key])) {
return null;
}
......
......@@ -111,6 +111,37 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_login()
{
$write = array(implode("\r\n", array(
'action: Login',
'actionid: 1432.123',
'username: foo',
'secret: bar',
''
)));
$action = new \PAMI\Message\Action\LoginAction('foo', 'bar');
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_login_with_events()
{
$write = array(implode("\r\n", array(
'action: Login',
'actionid: 1432.123',
'username: foo',
'secret: bar',
'events: all',
''
)));
$action = new \PAMI\Message\Action\LoginAction('foo', 'bar', 'all');
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_agent_logoff()
{
$write = array(implode("\r\n", array(
......@@ -156,6 +187,22 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_blindTransfer()
{
$write = array(implode("\r\n", array(
'action: BlindTransfer',
'actionid: 1432.123',
'channel: channel',
'exten: exten',
'context: context',
''
)));
$action = new \PAMI\Message\Action\BlindTransferAction('channel', 'exten', 'context');
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_bridge()
{
$write = array(implode("\r\n", array(
......@@ -172,6 +219,36 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_bridge_info()
{
$bridge_uniqueid = '57cb3a7e-0fa3-4e28-924f-d7728b0d7a9a';
$write = array(implode("\r\n", array(
'action: BridgeInfo',
'actionid: 1432.123',
'bridgeuniqueid: '. $bridge_uniqueid,
''
)));
$action = new \PAMI\Message\Action\BridgeInfoAction($bridge_uniqueid);
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_challenge()
{
$write = array(implode("\r\n", array(
'action: Challenge',
'actionid: 1432.123',
'authtype: test',
''
)));
$action = new \PAMI\Message\Action\ChallengeAction('test');
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_change_monitor()
{
$write = array(implode("\r\n", array(
......@@ -201,6 +278,21 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_confbridge_list()
{
$conference = 'conf-59dba3997444e5';
$write = array(implode("\r\n", array(
'action: ConfbridgeList',
'actionid: 1432.123',
'conference: ' . $conference,
''
)));
$action = new \PAMI\Message\Action\ConfbridgeListAction($conference);
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_confbridge_mute()
{
$write = array(implode("\r\n", array(
......@@ -485,6 +577,20 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_dahdi_transfer()
{
$write = array(implode("\r\n", array(
'action: DAHDITransfer',
'actionid: 1432.123',
'dahdichannel: channel',
''
)));
$action = new \PAMI\Message\Action\DAHDITransferAction('channel');
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_dbdel()
{
$write = array(implode("\r\n", array(
......@@ -647,6 +753,21 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_hangup_with_cause()
{
$write = array(implode("\r\n", array(
'action: Hangup',
'actionid: 1432.123',
'channel: channel',
'cause: 5',
''
)));
$action = new \PAMI\Message\Action\HangupAction('channel', 5);
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_jabbersend()
{
$write = array(implode("\r\n", array(
......@@ -1465,6 +1586,38 @@ class Test_Actions extends \PHPUnit_Framework_TestCase
/**
* @test
*/
public function can_user_event()
{
$write = array(implode("\r\n", array(
'action: UserEvent',
'actionid: 1432.123',
'userevent: FooEvent',
'foo: Bar',
'bar: Foo',
''
)));
$action = new \PAMI\Message\Action\UserEventAction('FooEvent', ['Foo' => 'Bar', 'Bar' => 'Foo']);
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_wait_event()
{
$write = array(implode("\r\n", array(
'action: WaitEvent',
'actionid: 1432.123',
'timeout: 20',
''
)));
$action = new \PAMI\Message\Action\WaitEventAction(20);
$client = $this->_start($write, $action);
}
/**
* @test
*/
public function can_set_actionid()
{
$action = new \PAMI\Message\Action\PingAction();
......
......@@ -72,7 +72,37 @@ class Test_Events extends \PHPUnit_Framework_TestCase
'DongleSMSStatus', 'FullyBooted', 'DongleShowDevicesComplete', 'DongleDeviceEntry',
'DongleNewUSSDBase64', 'DongleNewUSSD', 'DongleUSSDStatus', 'DongleNewCUSD',
'DongleStatus', 'CEL', 'JabberEvent', 'Registry', 'UserEvent',
'ParkedCall', 'UnParkedCall', 'Link'
'ParkedCall', 'UnParkedCall', 'Link',
'AGIExecStart',
'AGIExecEnd',
'AsyncAGIStart',
'AsyncAGIExec',
'AsyncAGIEnd',
'QueueCallerJoin',
'QueueCallerLeave',
'AttendedTransfer',
'BlindTransfer',
'DialBegin',
'DialEnd',
'DTMFBegin',
'DTMFEnd',
'BridgeCreate',
'BridgeDestroy',
'BridgeEnter',
'BridgeLeave',
'MusicOnHoldStart',
'MusicOnHoldStop',
'ConfbridgeStart',
'ConfbridgeEnd',
'ConfbridgeJoin',
'ConfbridgeLeave',
'ConfbridgeMute',
'ConfbridgeUnmute',
'ConfbridgeTalking',
'ConfbridgeList',
'ConfbridgeListComplete',
'BridgeInfoChannel',
'BridgeInfoComplete',
);
$eventTranslatedValues = array(
'QueueMemberStatus' => array(
......@@ -385,6 +415,7 @@ class Test_Events extends \PHPUnit_Framework_TestCase
'Application' => 'Application',
'Priority' => 'Priority',
'Extension' => 'Extension',
'Exten' => 'Exten',
'Context' => 'Context',
'UniqueID' => 'UniqueID',
),
......@@ -745,26 +776,82 @@ class Test_Events extends \PHPUnit_Framework_TestCase
'Privilege' => 'Privilege',
'Parkinglot' => 'Parkinglot',
'From' => 'From',
'Timeout' => 'Timeout',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'Channel' => 'Channel',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'UniqueID' => 'UniqueID',
'Exten' => 'Exten'
'Timeout' => 'ParkingTimeout',
'ConnectedLineNum' => 'ParkeeConnectedLineNum',
'ConnectedLineName' => 'ParkeeConnectedLineName',
'Channel' => 'ParkeeChannel',
'CallerIDNum' => 'ParkeeCallerIDNum',
'CallerIDName' => 'ParkeeCallerIDName',
'UniqueID' => 'ParkeeUniqueid',
'Exten' => 'ParkingSpace',
'ParkeeChannel' => 'ParkeeChannel',
'ParkeeChannelState' => 'ParkeeChannelState',
'ParkeeChannelStateDesc' => 'ParkeeChannelStateDesc',
'ParkeeCallerIDNum' => 'ParkeeCallerIDNum',
'ParkeeCallerIDName' => 'ParkeeCallerIDName',
'ParkeeConnectedLineNum' => 'ParkeeConnectedLineNum',
'ParkeeConnectedLineName' => 'ParkeeConnectedLineName',
'ParkeeAccountCode' => 'ParkeeAccountCode',
'ParkeeContext' => 'ParkeeContext',
'ParkeeExten' => 'ParkeeExten',
'ParkeePriority' => 'ParkeePriority',
'ParkeeUniqueid' => 'ParkeeUniqueid',
'ParkerDialString' => 'ParkerDialString',
'ParkingSpace' => 'ParkingSpace',
'ParkingTimeout' => 'ParkingTimeout',
'ParkingDuration' => 'ParkingDuration',
),
'UnParkedCall' => array(
'Privilege' => 'Privilege',
'Parkinglot' => 'Parkinglot',
'From' => 'From',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'Channel' => 'Channel',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'UniqueID' => 'UniqueID',
'Exten' => 'Exten'
'From' => 'RetrieverChannel',
'ConnectedLineNum' => 'ParkeeConnectedLineNum',
'ConnectedLineName' => 'ParkeeConnectedLineName',
'Channel' => 'ParkeeChannel',
'CallerIDNum' => 'ParkeeCallerIDNum',
'CallerIDName' => 'ParkeeCallerIDName',
'UniqueID' => 'ParkeeUniqueid',
'Exten' => 'ParkingSpace',
'ParkeeChannel' => 'ParkeeChannel',
'ParkeeChannelState' => 'ParkeeChannelState',
'ParkeeChannelStateDesc' => 'ParkeeChannelStateDesc',
'ParkeeCallerIDNum' => 'ParkeeCallerIDNum',
'ParkeeCallerIDName' => 'ParkeeCallerIDName',
'ParkeeConnectedLineNum' => 'ParkeeConnectedLineNum',
'ParkeeConnectedLineName' => 'ParkeeConnectedLineName',
'ParkeeAccountCode' => 'ParkeeAccountCode',
'ParkeeContext' => 'ParkeeContext',
'ParkeeExten' => 'ParkeeExten',
'ParkeePriority' => 'ParkeePriority',
'ParkeeUniqueid' => 'ParkeeUniqueid',
'ParkerDialString' => 'ParkerDialString',
'ParkingSpace' => 'ParkingSpace',
'ParkingTimeout' => 'ParkingTimeout',
'ParkingDuration' => 'ParkingDuration',
'ParkerChannel' => 'ParkerChannel',
'ParkerChannelState' => 'ParkerChannelState',
'ParkerChannelStateDesc' => 'ParkerChannelStateDesc',
'ParkerCallerIDNum' => 'ParkerCallerIDNum',
'ParkerCallerIDName' => 'ParkerCallerIDName',
'ParkerConnectedLineNum' => 'ParkerConnectedLineNum',
'ParkerConnectedLineName' => 'ParkerConnectedLineName',
'ParkerAccountCode' => 'ParkerAccountCode',
'ParkerContext' => 'ParkerContext',
'ParkerExten' => 'ParkerExten',
'ParkerPriority' => 'ParkerPriority',
'ParkerUniqueid' => 'ParkerUniqueid',
'RetrieverChannel' => 'RetrieverChannel',
'RetrieverChannelState' => 'RetrieverChannelState',
'RetrieverChannelStateDesc' => 'RetrieverChannelStateDesc',
'RetrieverCallerIDNum' => 'RetrieverCallerIDNum',
'RetrieverCallerIDName' => 'RetrieverCallerIDName',
'RetrieverConnectedLineNum' => 'RetrieverConnectedLineNum',
'RetrieverConnectedLineName' => 'RetrieverConnectedLineName',
'RetrieverAccountCode' => 'RetrieverAccountCode',
'RetrieverContext' => 'RetrieverContext',
'RetrieverExten' => 'RetrieverExten',
'RetrieverPriority' => 'RetrieverPriority',
'RetrieverUniqueid' => 'RetrieverUniqueid',
),
'Link' => array(
'Privilege' => 'Privilege',
......@@ -775,6 +862,580 @@ class Test_Events extends \PHPUnit_Framework_TestCase
'Channel1' => 'Channel1',
'Channel2' => 'Channel2'
),
'AGIExecStart' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Command' => 'Command',
'CommandId' => 'CommandId',
),
'AGIExecEnd' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Command' => 'Command',
'CommandId' => 'CommandId',
'ResultCode' => 'ResultCode',
'Result' => 'Result',
),
'AsyncAGIStart' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Env' => 'Env',
),
'AsyncAGIExec' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'CommandID' => 'CommandID',
'Result' => 'Result',
),
'AsyncAGIEnd' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
),
'QueueCallerJoin' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Queue' => 'Queue',
'Position' => 'Position',
'Count' => 'Count',
),
'QueueCallerLeave' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Queue' => 'Queue',
'Count' => 'Count',
'Position' => 'Position',
),
'AttendedTransfer' => array(
'Result' => 'Result',
'OrigTransfererChannel' => 'OrigTransfererChannel',
'OrigTransfererChannelState' => 'OrigTransfererChannelState',
'OrigTransfererChannelStateDesc' => 'OrigTransfererChannelStateDesc',
'OrigTransfererCallerIDNum' => 'OrigTransfererCallerIDNum',
'OrigTransfererCallerIDName' => 'OrigTransfererCallerIDName',
'OrigTransfererConnectedLineNum' => 'OrigTransfererConnectedLineNum',
'OrigTransfererConnectedLineName' => 'OrigTransfererConnectedLineName',
'OrigTransfererAccountCode' => 'OrigTransfererAccountCode',
'OrigTransfererContext' => 'OrigTransfererContext',
'OrigTransfererExten' => 'OrigTransfererExten',
'OrigTransfererPriority' => 'OrigTransfererPriority',
'OrigTransfererUniqueid' => 'OrigTransfererUniqueid',
'OrigBridgeUniqueid' => 'OrigBridgeUniqueid',
'OrigBridgeType' => 'OrigBridgeType',
'OrigBridgeTechnology' => 'OrigBridgeTechnology',
'OrigBridgeCreator' => 'OrigBridgeCreator',
'OrigBridgeName' => 'OrigBridgeName',
'OrigBridgeNumChannels' => 'OrigBridgeNumChannels',
'SecondTransfererChannel' => 'SecondTransfererChannel',
'SecondTransfererChannelState' => 'SecondTransfererChannelState',
'SecondTransfererChannelStateDesc' => 'SecondTransfererChannelStateDesc',
'SecondTransfererCallerIDNum' => 'SecondTransfererCallerIDNum',
'SecondTransfererCallerIDName' => 'SecondTransfererCallerIDName',
'SecondTransfererConnectedLineNum' => 'SecondTransfererConnectedLineNum',
'SecondTransfererConnectedLineName' => 'SecondTransfererConnectedLineName',
'SecondTransfererAccountCode' => 'SecondTransfererAccountCode',
'SecondTransfererContext' => 'SecondTransfererContext',
'SecondTransfererExten' => 'SecondTransfererExten',
'SecondTransfererPriority' => 'SecondTransfererPriority',
'SecondTransfererUniqueid' => 'SecondTransfererUniqueid',
'SecondBridgeUniqueid' => 'SecondBridgeUniqueid',
'SecondBridgeType' => 'SecondBridgeType',
'SecondBridgeTechnology' => 'SecondBridgeTechnology',
'SecondBridgeCreator' => 'SecondBridgeCreator',
'SecondBridgeName' => 'SecondBridgeName',
'SecondBridgeNumChannels' => 'SecondBridgeNumChannels',
'DestType' => 'DestType',
'DestBridgeUniqueid' => 'DestBridgeUniqueid',
'DestApp' => 'DestApp',
'LocalOneChannel' => 'LocalOneChannel',
'LocalOneChannelState' => 'LocalOneChannelState',
'LocalOneChannelStateDesc' => 'LocalOneChannelStateDesc',
'LocalOneCallerIDNum' => 'LocalOneCallerIDNum',
'LocalOneCallerIDName' => 'LocalOneCallerIDName',
'LocalOneConnectedLineNum' => 'LocalOneConnectedLineNum',
'LocalOneConnectedLineName' => 'LocalOneConnectedLineName',
'LocalOneAccountCode' => 'LocalOneAccountCode',
'LocalOneContext' => 'LocalOneContext',
'LocalOneExten' => 'LocalOneExten',
'LocalOnePriority' => 'LocalOnePriority',
'LocalOneUniqueid' => 'LocalOneUniqueid',
'LocalTwoChannel' => 'LocalTwoChannel',
'LocalTwoChannelState' => 'LocalTwoChannelState',
'LocalTwoChannelStateDesc' => 'LocalTwoChannelStateDesc',
'LocalTwoCallerIDNum' => 'LocalTwoCallerIDNum',
'LocalTwoCallerIDName' => 'LocalTwoCallerIDName',
'LocalTwoConnectedLineNum' => 'LocalTwoConnectedLineNum',
'LocalTwoConnectedLineName' => 'LocalTwoConnectedLineName',
'LocalTwoAccountCode' => 'LocalTwoAccountCode',
'LocalTwoContext' => 'LocalTwoContext',
'LocalTwoExten' => 'LocalTwoExten',
'LocalTwoPriority' => 'LocalTwoPriority',
'LocalTwoUniqueid' => 'LocalTwoUniqueid',
'DestTransfererChannel' => 'DestTransfererChannel',
'TransfereeChannel' => 'TransfereeChannel',
'TransfereeChannelState' => 'TransfereeChannelState',
'TransfereeChannelStateDesc' => 'TransfereeChannelStateDesc',
'TransfereeCallerIDNum' => 'TransfereeCallerIDNum',
'TransfereeCallerIDName' => 'TransfereeCallerIDName',
'TransfereeConnectedLineNum' => 'TransfereeConnectedLineNum',
'TransfereeConnectedLineName' => 'TransfereeConnectedLineName',
'TransfereeAccountCode' => 'TransfereeAccountCode',
'TransfereeContext' => 'TransfereeContext',
'TransfereeExten' => 'TransfereeExten',
'TransfereePriority' => 'TransfereePriority',
'TransfereeUniqueid' => 'TransfereeUniqueid',
),
'BlindTransfer' => array(
'Result' => 'Result',
'TransfererChannel' => 'TransfererChannel',
'TransfererChannelState' => 'TransfererChannelState',
'TransfererChannelStateDesc' => 'TransfererChannelStateDesc',
'TransfererCallerIDNum' => 'TransfererCallerIDNum',
'TransfererCallerIDName' => 'TransfererCallerIDName',
'TransfererConnectedLineNum' => 'TransfererConnectedLineNum',
'TransfererConnectedLineName' => 'TransfererConnectedLineName',
'TransfererAccountCode' => 'TransfererAccountCode',
'TransfererContext' => 'TransfererContext',
'TransfererExten' => 'TransfererExten',
'TransfererPriority' => 'TransfererPriority',
'TransfererUniqueid' => 'TransfererUniqueid',
'TransfereeChannel' => 'TransfereeChannel',
'TransfereeChannelState' => 'TransfereeChannelState',
'TransfereeChannelStateDesc' => 'TransfereeChannelStateDesc',
'TransfereeCallerIDNum' => 'TransfereeCallerIDNum',
'TransfereeCallerIDName' => 'TransfereeCallerIDName',
'TransfereeConnectedLineNum' => 'TransfereeConnectedLineNum',
'TransfereeConnectedLineName' => 'TransfereeConnectedLineName',
'TransfereeAccountCode' => 'TransfereeAccountCode',
'TransfereeContext' => 'TransfereeContext',
'TransfereeExten' => 'TransfereeExten',
'TransfereePriority' => 'TransfereePriority',
'TransfereeUniqueid' => 'TransfereeUniqueid',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'IsExternal' => 'IsExternal',
'Context' => 'Context',
'Extension' => 'Extension',
),
'DialBegin' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'DestChannel' => 'DestChannel',
'DestChannelState' => 'DestChannelState',
'DestChannelStateDesc' => 'DestChannelStateDesc',
'DestCallerIDNum' => 'DestCallerIDNum',
'DestCallerIDName' => 'DestCallerIDName',
'DestConnectedLineNum' => 'DestConnectedLineNum',
'DestConnectedLineName' => 'DestConnectedLineName',
'DestAccountCode' => 'DestAccountCode',
'DestContext' => 'DestContext',
'DestExten' => 'DestExten',
'DestPriority' => 'DestPriority',
'DestUniqueid' => 'DestUniqueid',
'DialString' => 'DialString',
),
'DialEnd' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'DestChannel' => 'DestChannel',
'DestChannelState' => 'DestChannelState',
'DestChannelStateDesc' => 'DestChannelStateDesc',
'DestCallerIDNum' => 'DestCallerIDNum',
'DestCallerIDName' => 'DestCallerIDName',
'DestConnectedLineNum' => 'DestConnectedLineNum',
'DestConnectedLineName' => 'DestConnectedLineName',
'DestAccountCode' => 'DestAccountCode',
'DestContext' => 'DestContext',
'DestExten' => 'DestExten',
'DestPriority' => 'DestPriority',
'DestUniqueid' => 'DestUniqueid',
'DialStatus' => 'DialStatus',
),
'DTMFBegin' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Digit' => 'Digit',
'Direction' => 'Direction',
),
'DTMFEnd' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Digit' => 'Digit',
'DurationMs' => 'DurationMs',
'Direction' => 'Direction',
),
'BridgeCreate' => array(
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
),
'BridgeDestroy' => array(
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
),
'BridgeEnter' => array(
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'SwapUniqueid' => 'SwapUniqueid',
),
'BridgeLeave' => array(
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
),
'MusicOnHoldStart' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Class' => 'Class',
),
'MusicOnHoldStop' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
),
'ConfbridgeStart' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
),
'ConfbridgeEnd' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
),
'ConfbridgeJoin' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
'Admin' => 'Admin',
),
'ConfbridgeLeave' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
'Admin' => 'Admin',
),
'ConfbridgeMute' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
'Admin' => 'Admin',
),
'ConfbridgeUnmute' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
'Admin' => 'Admin',
),
'ConfbridgeTalking' => array(
'Conference' => 'Conference',
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
'TalkingStatus' => 'TalkingStatus',
'Admin' => 'Admin',
),
'ConfbridgeList' => array(
'Conference' => 'Conference',
'Channel' => 'Channel',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'MarkedUser' => 'MarkedUser',
'WaitMarked' => 'WaitMarked',
'EndMarked' => 'EndMarked',
'Waiting' => 'Waiting',
'Muted' => 'Muted',
'AnsweredTime' => 'AnsweredTime',
'Admin' => 'Admin',
),
'ConfbridgeListComplete' => array('ListItems' => 'ListItems'),
'BridgeInfoChannel' => array(
'Channel' => 'Channel',
'ChannelState' => 'ChannelState',
'ChannelStateDesc' => 'ChannelStateDesc',
'CallerIDNum' => 'CallerIDNum',
'CallerIDName' => 'CallerIDName',
'ConnectedLineNum' => 'ConnectedLineNum',
'ConnectedLineName' => 'ConnectedLineName',
'AccountCode' => 'AccountCode',
'Context' => 'Context',
'Exten' => 'Exten',
'Priority' => 'Priority',
'Uniqueid' => 'Uniqueid',
'Linkedid' => 'Linkedid',
),
'BridgeInfoComplete' => array(
'BridgeUniqueid' => 'BridgeUniqueid',
'BridgeType' => 'BridgeType',
'BridgeTechnology' => 'BridgeTechnology',
'BridgeCreator' => 'BridgeCreator',
'BridgeName' => 'BridgeName',
'BridgeNumChannels' => 'BridgeNumChannels',
'BridgeVideoSourceMode' => 'BridgeVideoSourceMode',
'BridgeVideoSource' => 'BridgeVideoSource',
),
);
$eventGetters = array(
'UserEvent' => array(
......@@ -843,7 +1504,10 @@ class Test_Events extends \PHPUnit_Framework_TestCase
'X-vGSM-ME-State' => 'State',
),
'ParkedCall' => array('Exten' => 'Extension'),
'UnParkedCall' => array('Exten' => 'Extension')
'UnParkedCall' => array('Exten' => 'Extension'),
'AGIExecStart' => array(
),
);
foreach ($eventNames as $eventName) {
$this->_testEvent($eventName, $eventGetters, $eventValues[$eventName], $eventTranslatedValues);
......@@ -896,7 +1560,13 @@ class Test_Events extends \PHPUnit_Framework_TestCase
if (isset($translatedValues[$eventName][$key])) {
$value = $translatedValues[$eventName][$key];
}
$this->assertEquals($event->$methodName(), $value);
$this->assertTrue(
method_exists($event, $methodName),
sprintf('Method %s doesn\'t exixt in event %s', $methodName, get_class($event))
);
$this->assertEquals($event->$methodName(), $value, $eventName);
}
}
}
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!