diff --git a/src/PAMI/Message/Action/ConfbridgeKickAction.php b/src/PAMI/Message/Action/ConfbridgeKickAction.php new file mode 100644 index 000000000..043133658 --- /dev/null +++ b/src/PAMI/Message/Action/ConfbridgeKickAction.php @@ -0,0 +1,46 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * + * Copyright 2011 Marcelo Gornstein + * + * 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. + * + */ +class ConfbridgeKickAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $channel Channel to be muted. + * @param string $conference Conference on which to act. + * + * @return void + */ + public function __construct($channel, $conference) + { + parent::__construct('ConfbridgeKick'); + $this->setKey('Channel', $channel); + $this->setKey('Conference', $conference); + } +} diff --git a/src/PAMI/Message/Action/ConfbridgeLockAction.php b/src/PAMI/Message/Action/ConfbridgeLockAction.php new file mode 100644 index 000000000..f8b4968ed --- /dev/null +++ b/src/PAMI/Message/Action/ConfbridgeLockAction.php @@ -0,0 +1,44 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * + * Copyright 2011 Marcelo Gornstein + * + * 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. + * + */ +class ConfbridgeLockAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $conference Conference on which to act. + * + * @return void + */ + public function __construct($conference) + { + parent::__construct('ConfbridgeLock'); + $this->setKey('Conference', $conference); + } +} diff --git a/src/PAMI/Message/Action/ConfbridgeUnlockAction.php b/src/PAMI/Message/Action/ConfbridgeUnlockAction.php new file mode 100644 index 000000000..fcadffa00 --- /dev/null +++ b/src/PAMI/Message/Action/ConfbridgeUnlockAction.php @@ -0,0 +1,44 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * + * Copyright 2011 Marcelo Gornstein + * + * 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. + * + */ +class ConfbridgeUnlockAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $conference Conference on which to act. + * + * @return void + */ + public function __construct($conference) + { + parent::__construct('ConfbridgeUnlock'); + $this->setKey('Conference', $conference); + } +} diff --git a/src/PAMI/Message/Action/GetConfigAction.php b/src/PAMI/Message/Action/GetConfigAction.php index 327389668..61a108a03 100644 --- a/src/PAMI/Message/Action/GetConfigAction.php +++ b/src/PAMI/Message/Action/GetConfigAction.php @@ -47,16 +47,19 @@ class GetConfigAction extends ActionMessage * Constructor. * * @param string $filename Configuration filename (e.g.: foo.conf). - * @param boolean $category Category in configuration file. + * @param string $category Contect name in ini file (e.g.: [general]). * * @return void */ - public function __construct($filename, $category = false) + public function __construct($filename, $category = false, $filter = false) { parent::__construct('GetConfig'); $this->setKey('Filename', $filename); if ($category != false) { $this->setKey('Category', $category); } + if ($filter != false) { + $this->setKey('Filter', $filter); + } } } diff --git a/src/PAMI/Message/Action/GetConfigJSONAction.php b/src/PAMI/Message/Action/GetConfigJSONAction.php index 3bcb4d2e0..01b007875 100644 --- a/src/PAMI/Message/Action/GetConfigJSONAction.php +++ b/src/PAMI/Message/Action/GetConfigJSONAction.php @@ -47,12 +47,19 @@ class GetConfigJSONAction extends ActionMessage * Constructor. * * @param string $filename Configuration filename (e.g.: foo.conf). + * @param string $category Contect name in ini file (e.g.: [general]). * * @return void */ - public function __construct($filename) + public function __construct($filename, $category = false, $filter = false) { parent::__construct('GetConfigJSON'); $this->setKey('Filename', $filename); + if ($category != false) { + $this->setKey('Category', $category); + } + if ($filter != false) { + $this->setKey('Filter', $filter); + } } } diff --git a/src/PAMI/Message/Action/PJSIPNotifyAction.php b/src/PAMI/Message/Action/PJSIPNotifyAction.php new file mode 100644 index 000000000..501fc0f06 --- /dev/null +++ b/src/PAMI/Message/Action/PJSIPNotifyAction.php @@ -0,0 +1,70 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * PJSIPNotify action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class PJSIPNotifyAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $endpoint PJSIP endpoint or URI to receive the notify. + * @param array/string $variables Variable Key-Value pairs / pjsip_notify.conf context (section) name. + * + * @return void + */ + public function __construct($endpoint, $variables) + { + parent::__construct('PJSIPNotify'); + if (strpos($endpoint, "@") !== false) { + $this->setKey('URI', $endpoint); + } else { + $this->setKey('Endpoint', $endpoint); + } + if (is_array($variables)) { + foreach ($variables as $key => $value) { + $this->setKey('Variable', $key . '=' . $value); + } + } else { + $this->setKey('Option', $variables); + } + } +} diff --git a/src/PAMI/Message/Action/PJSIPShowContactsAction.php b/src/PAMI/Message/Action/PJSIPShowContactsAction.php new file mode 100644 index 000000000..afdca7411 --- /dev/null +++ b/src/PAMI/Message/Action/PJSIPShowContactsAction.php @@ -0,0 +1,55 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2022 Morvai Szabolcs + * + * 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; + +/** + * PJSIPShowContacts action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Morvai Szabolcs + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class PJSIPShowContactsAction extends ActionMessage +{ + /** + * Constructor. + * + * @return void + */ + public function __construct() + { + parent::__construct('PJSIPShowContacts'); + } +} diff --git a/src/PAMI/Message/Action/PJSIPShowEndpointAction.php b/src/PAMI/Message/Action/PJSIPShowEndpointAction.php new file mode 100644 index 000000000..5d768344c --- /dev/null +++ b/src/PAMI/Message/Action/PJSIPShowEndpointAction.php @@ -0,0 +1,58 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2022 Morvai Szabolcs + * + * 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; + +/** + * PJSIPShowEndpoint action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Morvai Szabolcs + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class PJSIPShowEndpointAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $endpoint Endpoint name. + * + * @return void + */ + public function __construct($endpoint) + { + parent::__construct('PJSIPShowEndpoint'); + $this->setKey('Endpoint', $endpoint); + } +} diff --git a/src/PAMI/Message/Action/SIPNotifyAction.php b/src/PAMI/Message/Action/SIPNotifyAction.php index 9e6d54fc3..9c72cb11d 100644 --- a/src/PAMI/Message/Action/SIPNotifyAction.php +++ b/src/PAMI/Message/Action/SIPNotifyAction.php @@ -47,12 +47,16 @@ class SIPNotifyAction extends ActionMessage * Constructor. * * @param string $channel Peer to receive the notify. + * @param array $variables Variable Key-Value pairs. * * @return void */ - public function __construct($channel) + public function __construct($channel, $variables) { parent::__construct('SIPnotify'); $this->setKey('Channel', $channel); + foreach ($variables as $key => $value) { + $this->setKey('Variable', $key . '=' . $value); + } } } diff --git a/src/PAMI/Message/Action/SorceryMemoryCacheExpireAction.php b/src/PAMI/Message/Action/SorceryMemoryCacheExpireAction.php new file mode 100644 index 000000000..4eded4c85 --- /dev/null +++ b/src/PAMI/Message/Action/SorceryMemoryCacheExpireAction.php @@ -0,0 +1,58 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * SorceryMemoryCacheExpire action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class SorceryMemoryCacheExpireAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $cache Cache name. + * + * @return void + */ + public function __construct($cache) + { + parent::__construct('SorceryMemoryCacheExpire'); + $this->setKey('Cache', $cache); + } +} diff --git a/src/PAMI/Message/Action/SorceryMemoryCacheExpireObjectAction.php b/src/PAMI/Message/Action/SorceryMemoryCacheExpireObjectAction.php new file mode 100644 index 000000000..e14679804 --- /dev/null +++ b/src/PAMI/Message/Action/SorceryMemoryCacheExpireObjectAction.php @@ -0,0 +1,60 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * SorceryMemoryCacheExpireObject action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class SorceryMemoryCacheExpireObjectAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $cache Cache name. + * @param string $object Object name. + * + * @return void + */ + public function __construct($cache, $object) + { + parent::__construct('SorceryMemoryCacheExpireObject'); + $this->setKey('Cache', $cache); + $this->setKey('Object', $object); + } +} diff --git a/src/PAMI/Message/Action/SorceryMemoryCachePopulateAction.php b/src/PAMI/Message/Action/SorceryMemoryCachePopulateAction.php new file mode 100644 index 000000000..83ab8ea54 --- /dev/null +++ b/src/PAMI/Message/Action/SorceryMemoryCachePopulateAction.php @@ -0,0 +1,58 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * SorceryMemoryCachePopulate action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class SorceryMemoryCachePopulateAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $cache Cache name. + * + * @return void + */ + public function __construct($cache) + { + parent::__construct('SorceryMemoryCachePopulate'); + $this->setKey('Cache', $cache); + } +} diff --git a/src/PAMI/Message/Action/SorceryMemoryCacheStaleAction.php b/src/PAMI/Message/Action/SorceryMemoryCacheStaleAction.php new file mode 100644 index 000000000..8d265243c --- /dev/null +++ b/src/PAMI/Message/Action/SorceryMemoryCacheStaleAction.php @@ -0,0 +1,58 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * SorceryMemoryCacheStale action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class SorceryMemoryCacheStaleAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $cache Cache name. + * + * @return void + */ + public function __construct($cache) + { + parent::__construct('SorceryMemoryCacheStale'); + $this->setKey('Cache', $cache); + } +} diff --git a/src/PAMI/Message/Action/SorceryMemoryCacheStaleObjectAction.php b/src/PAMI/Message/Action/SorceryMemoryCacheStaleObjectAction.php new file mode 100644 index 000000000..ab0e36146 --- /dev/null +++ b/src/PAMI/Message/Action/SorceryMemoryCacheStaleObjectAction.php @@ -0,0 +1,64 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * SorceryMemoryCacheStaleObject action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class SorceryMemoryCacheStaleObjectAction extends ActionMessage +{ + /** + * Constructor. + * + * @param string $cache Cache name. + * @param string $object Object name. + * @param bool $reload Reload from backend. + * + * @return void + */ + public function __construct($cache, $object, $reload = false) + { + parent::__construct('SorceryMemoryCacheStaleObject'); + $this->setKey('Cache', $cache); + $this->setKey('Object', $object); + if ($reload !== false) { + $this->setKey('Reload', 'true'); + } + } +} diff --git a/src/PAMI/Message/Action/VoicemailRefreshAction.php b/src/PAMI/Message/Action/VoicemailRefreshAction.php new file mode 100644 index 000000000..c87248413 --- /dev/null +++ b/src/PAMI/Message/Action/VoicemailRefreshAction.php @@ -0,0 +1,61 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * VoicemailRefresh action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class VoicemailRefreshAction extends ActionMessage +{ + /** + * Constructor. + * + * @return void + */ + public function __construct($context = false, $mailbox = false) + { + parent::__construct('VoicemailRefresh'); + if($context != false){ + $this->setKey('Context', $context); + if($mailbox != false){ + $this->setKey('Mailbox', $mailbox); + } + } + } +} diff --git a/src/PAMI/Message/Action/VoicemailUserStatusAction.php b/src/PAMI/Message/Action/VoicemailUserStatusAction.php new file mode 100644 index 000000000..561df93e6 --- /dev/null +++ b/src/PAMI/Message/Action/VoicemailUserStatusAction.php @@ -0,0 +1,57 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2023 Sperl Viktor + * + * 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; + +/** + * VoicemailUserStatus action message. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Action + * @author Sperl Viktor + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class VoicemailUserStatusAction extends ActionMessage +{ + /** + * Constructor. + * + * @return void + */ + public function __construct($context, $mailbox) + { + parent::__construct('VoicemailUserStatus'); + $this->setKey('Context', $context); + $this->setKey('Mailbox', $mailbox); + } +} diff --git a/src/PAMI/Message/Event/BridgeEnterEvent.php b/src/PAMI/Message/Event/BridgeEnterEvent.php index 2be6dd8b1..c965c8081 100644 --- a/src/PAMI/Message/Event/BridgeEnterEvent.php +++ b/src/PAMI/Message/Event/BridgeEnterEvent.php @@ -63,6 +63,16 @@ public function getBridgeUniqueid() return $this->getKey('BridgeUniqueid'); } + /** + * Returns key: 'Linkedid'. + * + * @return string + */ + public function getLinkedid() + { + return $this->getKey('Linkedid'); + } + /** * Returns key: 'BridgeType'. * diff --git a/src/PAMI/Message/Event/ContactListEvent.php b/src/PAMI/Message/Event/ContactListEvent.php new file mode 100644 index 000000000..391a770ca --- /dev/null +++ b/src/PAMI/Message/Event/ContactListEvent.php @@ -0,0 +1,217 @@ + + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @version SVN: $Id$ + * @link http://marcelog.github.com/PAMI/ + * + * Copyright 2011 Morvai Szabolcs + * + * 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 when a dial is executed. + * + * PHP Version 5 + * + * @category Pami + * @package Message + * @subpackage Event + * @author Morvai Szabolcs + * @license http://marcelog.github.com/PAMI/ Apache License 2.0 + * @link http://marcelog.github.com/PAMI/ + */ +class ContactListEvent extends EventMessage +{ + /** + * Returns key: 'ObjectType'. + * + * @return string + */ + public function getObjectType() + { + return $this->getKey('ObjectType'); + } + + /** + * Returns key: 'ObjectName'. + * + * @return string + */ + public function getObjectName() + { + return $this->getKey('ObjectName'); + } + + /** + * Returns key: 'ViaAddr'. + * + * @return string + */ + public function getViaAddr() + { + return $this->getKey('ViaAddr'); + } + + /** + * Returns key: 'QualifyTimeout'. + * + * @return string + */ + public function getQualifyTimeout() + { + return $this->getKey('QualifyTimeout'); + } + + /** + * Returns key: 'CallId'. + * + * @return string + */ + public function getCallId() + { + return $this->getKey('CallId'); + } + + /** + * Returns key: 'RegServer'. + * + * @return string + */ + public function getRegServer() + { + return $this->getKey('RegServer'); + } + + /** + * Returns key: 'PruneOnBoot'. + * + * @return string + */ + public function getPruneOnBoot() + { + return $this->getKey('PruneOnBoot'); + } + + /** + * Returns key: 'Path'. + * + * @return string + */ + public function getPath() + { + return $this->getKey('Path'); + } + + /** + * Returns key: 'Endpoint'. + * + * @return string + */ + public function getEndpoint() + { + return $this->getKey('Endpoint'); + } + + /** + * Returns key: 'ViaPort'. + * + * @return string + */ + public function getViaPort() + { + return $this->getKey('ViaPort'); + } + + /** + * Returns key: 'AuthenticateQualify'. + * + * @return string + */ + public function getAuthenticateQualify() + { + return $this->getKey('AuthenticateQualify'); + } + + /** + * Returns key: 'Uri'. + * + * @return string + */ + public function getUri() + { + return $this->getKey('Uri'); + } + + /** + * Returns key: 'QualifyFrequency'. + * + * @return string + */ + public function getQualifyFrequency() + { + return $this->getKey('QualifyFrequency'); + } + + /** + * Returns key: 'UserAgent'. + * + * @return string + */ + public function getUserAgent() + { + return $this->getKey('UserAgent'); + } + + /** + * Returns key: 'ExpirationTime'. + * + * @return string + */ + public function getExpirationTime() + { + return $this->getKey('ExpirationTime'); + } + + /** + * Returns key: 'OutboundProxy'. + * + * @return string + */ + public function getOutboundProxy() + { + return $this->getKey('OutboundProxy'); + } + + /** + * Returns key: 'Status'. + * + * @return string + */ + public function getStatus() + { + return $this->getKey('Status'); + } +} diff --git a/src/PAMI/Message/Event/HangupEvent.php b/src/PAMI/Message/Event/HangupEvent.php index 2cb09c791..3e4aa95e7 100644 --- a/src/PAMI/Message/Event/HangupEvent.php +++ b/src/PAMI/Message/Event/HangupEvent.php @@ -114,4 +114,14 @@ public function getCauseText() { return $this->getKey('Cause-txt'); } + + /** + * Returns key: 'AccountCode'. + * + * @return string + */ + public function getAccountCode() + { + return $this->getKey('AccountCode'); + } } diff --git a/src/PAMI/Message/Event/NewstateEvent.php b/src/PAMI/Message/Event/NewstateEvent.php index f2bc01cb3..74e69d9c6 100644 --- a/src/PAMI/Message/Event/NewstateEvent.php +++ b/src/PAMI/Message/Event/NewstateEvent.php @@ -117,6 +117,16 @@ public function getUniqueID() return $this->getKey('UniqueID'); } + /** + * Returns key: 'Linkedid'. + * + * @return string + */ + public function getLinkedid() + { + return $this->getKey('Linkedid'); + } + /** * Returns key: 'ConnectedLineNum'. Asterisk >= 1.8. *