6016f892 by Manish Mihsra

Added updated Marcelog and new logic implementation call transfer

1 parent 5189ce7c
Showing 1000 changed files with 5256 additions and 7 deletions

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.

...@@ -313,7 +313,7 @@ class DialerController extends Controller { ...@@ -313,7 +313,7 @@ class DialerController extends Controller {
313 if($sipid&&$sipid->user==Auth::user()->id&&$sipid->status==1) 313 if($sipid&&$sipid->user==Auth::user()->id&&$sipid->status==1)
314 { 314 {
315 315
316 $dialline=Dialline::where("status","=","Free")->where("enabled","=","1"); 316 $dialline=Dialline::where('server', '=', env('app_ip'))->where("status","=","Free")->where("enabled","=","1");
317 if($dspan!="")$dialline=$dialline->where('dspan','=',$dspan); 317 if($dspan!="")$dialline=$dialline->where('dspan','=',$dspan);
318 $dialline=$dialline->orderBy('updated_at','ASC')->first(); 318 $dialline=$dialline->orderBy('updated_at','ASC')->first();
319 319
...@@ -456,8 +456,8 @@ if($action=="addconfcall") ...@@ -456,8 +456,8 @@ if($action=="addconfcall")
456 456
457 457
458 //start actual calls 458 //start actual calls
459 $newqueue=new Kqueue(); 459 // $newqueue=new Kqueue();
460 $newqueue->userToConf($sipid); 460 // $newqueue->userToConf($sipid);
461 $newqueue=new Kqueue(); 461 $newqueue=new Kqueue();
462 $newqueue->custToConf($sipid,$callnumber,$callerid,$crmcall,$dialline); 462 $newqueue->custToConf($sipid,$callnumber,$callerid,$crmcall,$dialline);
463 463
...@@ -481,6 +481,90 @@ if($action=="addconfcall") ...@@ -481,6 +481,90 @@ if($action=="addconfcall")
481 return Response::make($retstr); 481 return Response::make($retstr);
482 } 482 }
483 483
484 if($action=="transfercall")
485 {
486 $retstr="";
487 $callnumber=Input::get("confnumber");
488 $callerid="";
489
490 //see if user is online on this sipid
491 $sipid=Sipid::find($kstychDialer['phone']);
492 if($sipid&&$sipid->user==Auth::user()->id&&$sipid->status==1)
493 {
494 $oldcrmcall=CRMCall::find($kstychCall['callid']);
495 if($oldcrmcall)
496 {
497 $olddialline=Dialline::find($oldcrmcall->dialline_id);
498 $dspan="1";if($olddialline)$dspan=$olddialline->dspan;
499
500 $dialline=Dialline::where("status","=","Free")->where("enabled","=","1");
501 if($dspan!="")$dialline=$dialline->where('dspan','=',$dspan);
502 $dialline=$dialline->orderBy('updated_at','ASC')->first();
503
504 if($dialline)
505 {
506
507 $callerid=$oldcrmcall->did;
508
509 $dialline->status="transfer";
510 $dialline->channel=$olddialline->channel;
511 $dialline->save();
512
513 $nowts=microtime(true)*1000;
514
515 //start the call log
516 $crmcall=new CRMCall();
517 $crmcall->number=$callnumber;
518 $crmcall->user_id=Auth::user()->id;
519 $crmcall->sipid_id=$sipid->id;
520 $crmcall->crm_id=$oldcrmcall->crm_id;
521 $crmcall->client=$oldcrmcall->client;
522 $crmcall->department=$oldcrmcall->department;
523 $crmcall->state='New';
524 $crmcall->userstatus='Conference';
525 $crmcall->usersubstatus='Conference';
526 $crmcall->type='Conference';
527 $crmcall->dialline_id=$dialline->id;
528
529 $crmcall->setTs('ts_Wait',$nowts);
530 $crmcall->setTs('ts_Call',$nowts);
531
532 $crmcall->did=$callerid;
533
534 $tdata=array();
535 $crmcall->data=json_encode($tdata);
536 $crmcall->save();
537
538
539 $newqueue=new Kqueue();
540 $newqueue->transferCall($sipid,$callnumber,$callerid,$crmcall,$dialline);
541
542 //start actual calls
543 // $newqueue=new Kqueue();
544 // $newqueue->userToConf($sipid);
545 // $newqueue=new Kqueue();
546 // $newqueue->custToConf($sipid,$callnumber,$callerid,$crmcall,$dialline);
547
548 $retstr=$crmcall->id;
549 }
550 else
551 {
552 $retstr="Error : No Lines Free to Dial!";
553 }
554 }
555 else
556 {
557 $retstr="Error : No calls to conference found!";
558 }
559 }
560 else
561 {
562 $retstr="Error : You Are Not Connected!";
563 }
564
565 return Response::make($retstr);
566 }
567
484 if($action=="hangupall") 568 if($action=="hangupall")
485 { 569 {
486 $res=0; 570 $res=0;
......
...@@ -17,6 +17,7 @@ use Request; ...@@ -17,6 +17,7 @@ use Request;
17 use Cache; 17 use Cache;
18 use File; 18 use File;
19 use Route; 19 use Route;
20 use Log;
20 21
21 use App\Models\Group; 22 use App\Models\Group;
22 use App\Models\Sipid; 23 use App\Models\Sipid;
...@@ -103,9 +104,7 @@ class HomeController extends Controller { ...@@ -103,9 +104,7 @@ class HomeController extends Controller {
103 $cliarr['keepconf']=Config::get("app.kDialer_keeplocalconf"); 104 $cliarr['keepconf']=Config::get("app.kDialer_keeplocalconf");
104 //get a free sip id 105 //get a free sip id
105 $server=explode(":",$user->exten); 106 $server=explode(":",$user->exten);
106 $sipid=Sipid::where("status","=","0")->where('updated_at','<=',date("Y-m-d H:i:s",time()-600))->orderBy('updated_at','asc')->where('server','!=',''); 107 $sipid=Sipid::where("status","=","0")->where('updated_at','<=',date("Y-m-d H:i:s",time()-600))->orderBy('updated_at','asc')->where('server','=',env('app_ip'))->first();
107 if(isset($server[2]))$sipid=$sipid->where('server','=',$server[2]);
108 $sipid=$sipid->first();
109 if(!$sipid)return Response::make("Error : Cant Allocate Data Channel. Giving Up."); 108 if(!$sipid)return Response::make("Error : Cant Allocate Data Channel. Giving Up.");
110 $sipid->clients=json_encode($cliarr); 109 $sipid->clients=json_encode($cliarr);
111 $sipid->user=$user->id; 110 $sipid->user=$user->id;
......
1 <?php namespace App\Models; 1 <?php namespace App\Models;
2 use Illuminate\Database\Eloquent\Model; 2 use Illuminate\Database\Eloquent\Model;
3 3 use Log;
4 4
5 class Kqueue extends Model{ 5 class Kqueue extends Model{
6 6
...@@ -69,6 +69,33 @@ class Kqueue extends Model{ ...@@ -69,6 +69,33 @@ class Kqueue extends Model{
69 } 69 }
70 70
71 } 71 }
72 public function transferCall($sipid,$callnumber,$callerid,$crmcall,$dialline)
73 {
74 $dialstr = $dialline->dialstr;
75 $server = $dialline->server;
76 $channel = $dialline->channel;
77 Log::info($channel);
78 if($server != '')
79 {
80 $odata=array();$odata['VARS']=array();
81 $odata['fromext']="Local/1000".$sipid->id."@kstychDialer";
82 $odata['context']="initiateTransfer";
83 $odata['callerid']=$channel;
84 $odata['toext']="1003".$callnumber;
85 $odata['account']='m|t|'.$crmcall->id;
86 $odata['VARS']['dialstr']=$dialstr;
87 $odata['VARS']['chnl']=$channel;
88 $odata['VARS']['callnumber']=$callnumber;
89
90 //originate conf
91 $this->type="SIP_".$server;
92 $this->key="originate";
93 $this->status="New";
94 $this->data=json_encode($odata);
95 $this->save();
96 }
97
98 }
72 public function sipOriginate($sipid,$to,$context) 99 public function sipOriginate($sipid,$to,$context)
73 { 100 {
74 $odata=array();$odata['VARS']=array(); 101 $odata=array();$odata['VARS']=array();
......
1 engines:
2 duplication:
3 enabled: true
4 config:
5 languages:
6 - php
7 fixme:
8 enabled: false
9 phpcodesniffer:
10 enabled: true
11 phpmd:
12 enabled: true
13
14 ratings:
15 paths:
16 - "**.php"
17
18 exclude_paths:
19 - test/**/*
...\ No newline at end of file ...\ No newline at end of file
1 vendor
2 .buildpath
3 .settings
4 .project
5 build
6 resources/php.ini
7 composer.lock
8 nbproject
1 language: php
2 php:
3 - '5.4'
4 - '5.5'
5 - '5.6'
6 - '7.0'
7
8 before_script:
9 - phpenv config-add test/resources/php.ini
10
11 install:
12 - composer install
13
14 script:
15 - vendor/bin/phing build
16
17 after_script:
18 - travis_retry php vendor/bin/coveralls -v
19 - vendor/bin/test-reporter
20
21 addons:
22 code_climate:
23 repo_token: 568675e210a5bfc69593877127f7297bab3150dc4d26692bd19bc49c75bd2c14
...\ No newline at end of file ...\ No newline at end of file
1
2 Apache License
3 Version 2.0, January 2004
4 http://www.apache.org/licenses/
5
6 TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
8 1. Definitions.
9
10 "License" shall mean the terms and conditions for use, reproduction,
11 and distribution as defined by Sections 1 through 9 of this document.
12
13 "Licensor" shall mean the copyright owner or entity authorized by
14 the copyright owner that is granting the License.
15
16 "Legal Entity" shall mean the union of the acting entity and all
17 other entities that control, are controlled by, or are under common
18 control with that entity. For the purposes of this definition,
19 "control" means (i) the power, direct or indirect, to cause the
20 direction or management of such entity, whether by contract or
21 otherwise, or (ii) ownership of fifty percent (50%) or more of the
22 outstanding shares, or (iii) beneficial ownership of such entity.
23
24 "You" (or "Your") shall mean an individual or Legal Entity
25 exercising permissions granted by this License.
26
27 "Source" form shall mean the preferred form for making modifications,
28 including but not limited to software source code, documentation
29 source, and configuration files.
30
31 "Object" form shall mean any form resulting from mechanical
32 transformation or translation of a Source form, including but
33 not limited to compiled object code, generated documentation,
34 and conversions to other media types.
35
36 "Work" shall mean the work of authorship, whether in Source or
37 Object form, made available under the License, as indicated by a
38 copyright notice that is included in or attached to the work
39 (an example is provided in the Appendix below).
40
41 "Derivative Works" shall mean any work, whether in Source or Object
42 form, that is based on (or derived from) the Work and for which the
43 editorial revisions, annotations, elaborations, or other modifications
44 represent, as a whole, an original work of authorship. For the purposes
45 of this License, Derivative Works shall not include works that remain
46 separable from, or merely link (or bind by name) to the interfaces of,
47 the Work and Derivative Works thereof.
48
49 "Contribution" shall mean any work of authorship, including
50 the original version of the Work and any modifications or additions
51 to that Work or Derivative Works thereof, that is intentionally
52 submitted to Licensor for inclusion in the Work by the copyright owner
53 or by an individual or Legal Entity authorized to submit on behalf of
54 the copyright owner. For the purposes of this definition, "submitted"
55 means any form of electronic, verbal, or written communication sent
56 to the Licensor or its representatives, including but not limited to
57 communication on electronic mailing lists, source code control systems,
58 and issue tracking systems that are managed by, or on behalf of, the
59 Licensor for the purpose of discussing and improving the Work, but
60 excluding communication that is conspicuously marked or otherwise
61 designated in writing by the copyright owner as "Not a Contribution."
62
63 "Contributor" shall mean Licensor and any individual or Legal Entity
64 on behalf of whom a Contribution has been received by Licensor and
65 subsequently incorporated within the Work.
66
67 2. Grant of Copyright License. Subject to the terms and conditions of
68 this License, each Contributor hereby grants to You a perpetual,
69 worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70 copyright license to reproduce, prepare Derivative Works of,
71 publicly display, publicly perform, sublicense, and distribute the
72 Work and such Derivative Works in Source or Object form.
73
74 3. Grant of Patent License. Subject to the terms and conditions of
75 this License, each Contributor hereby grants to You a perpetual,
76 worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77 (except as stated in this section) patent license to make, have made,
78 use, offer to sell, sell, import, and otherwise transfer the Work,
79 where such license applies only to those patent claims licensable
80 by such Contributor that are necessarily infringed by their
81 Contribution(s) alone or by combination of their Contribution(s)
82 with the Work to which such Contribution(s) was submitted. If You
83 institute patent litigation against any entity (including a
84 cross-claim or counterclaim in a lawsuit) alleging that the Work
85 or a Contribution incorporated within the Work constitutes direct
86 or contributory patent infringement, then any patent licenses
87 granted to You under this License for that Work shall terminate
88 as of the date such litigation is filed.
89
90 4. Redistribution. You may reproduce and distribute copies of the
91 Work or Derivative Works thereof in any medium, with or without
92 modifications, and in Source or Object form, provided that You
93 meet the following conditions:
94
95 (a) You must give any other recipients of the Work or
96 Derivative Works a copy of this License; and
97
98 (b) You must cause any modified files to carry prominent notices
99 stating that You changed the files; and
100
101 (c) You must retain, in the Source form of any Derivative Works
102 that You distribute, all copyright, patent, trademark, and
103 attribution notices from the Source form of the Work,
104 excluding those notices that do not pertain to any part of
105 the Derivative Works; and
106
107 (d) If the Work includes a "NOTICE" text file as part of its
108 distribution, then any Derivative Works that You distribute must
109 include a readable copy of the attribution notices contained
110 within such NOTICE file, excluding those notices that do not
111 pertain to any part of the Derivative Works, in at least one
112 of the following places: within a NOTICE text file distributed
113 as part of the Derivative Works; within the Source form or
114 documentation, if provided along with the Derivative Works; or,
115 within a display generated by the Derivative Works, if and
116 wherever such third-party notices normally appear. The contents
117 of the NOTICE file are for informational purposes only and
118 do not modify the License. You may add Your own attribution
119 notices within Derivative Works that You distribute, alongside
120 or as an addendum to the NOTICE text from the Work, provided
121 that such additional attribution notices cannot be construed
122 as modifying the License.
123
124 You may add Your own copyright statement to Your modifications and
125 may provide additional or different license terms and conditions
126 for use, reproduction, or distribution of Your modifications, or
127 for any such Derivative Works as a whole, provided Your use,
128 reproduction, and distribution of the Work otherwise complies with
129 the conditions stated in this License.
130
131 5. Submission of Contributions. Unless You explicitly state otherwise,
132 any Contribution intentionally submitted for inclusion in the Work
133 by You to the Licensor shall be under the terms and conditions of
134 this License, without any additional terms or conditions.
135 Notwithstanding the above, nothing herein shall supersede or modify
136 the terms of any separate license agreement you may have executed
137 with Licensor regarding such Contributions.
138
139 6. Trademarks. This License does not grant permission to use the trade
140 names, trademarks, service marks, or product names of the Licensor,
141 except as required for reasonable and customary use in describing the
142 origin of the Work and reproducing the content of the NOTICE file.
143
144 7. Disclaimer of Warranty. Unless required by applicable law or
145 agreed to in writing, Licensor provides the Work (and each
146 Contributor provides its Contributions) on an "AS IS" BASIS,
147 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148 implied, including, without limitation, any warranties or conditions
149 of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150 PARTICULAR PURPOSE. You are solely responsible for determining the
151 appropriateness of using or redistributing the Work and assume any
152 risks associated with Your exercise of permissions under this License.
153
154 8. Limitation of Liability. In no event and under no legal theory,
155 whether in tort (including negligence), contract, or otherwise,
156 unless required by applicable law (such as deliberate and grossly
157 negligent acts) or agreed to in writing, shall any Contributor be
158 liable to You for damages, including any direct, indirect, special,
159 incidental, or consequential damages of any character arising as a
160 result of this License or out of the use or inability to use the
161 Work (including but not limited to damages for loss of goodwill,
162 work stoppage, computer failure or malfunction, or any and all
163 other commercial damages or losses), even if such Contributor
164 has been advised of the possibility of such damages.
165
166 9. Accepting Warranty or Additional Liability. While redistributing
167 the Work or Derivative Works thereof, You may choose to offer,
168 and charge a fee for, acceptance of support, warranty, indemnity,
169 or other liability obligations and/or rights consistent with this
170 License. However, in accepting such obligations, You may act only
171 on Your own behalf and on Your sole responsibility, not on behalf
172 of any other Contributor, and only if You agree to indemnify,
173 defend, and hold each Contributor harmless for any liability
174 incurred by, or claims asserted against, such Contributor by reason
175 of your accepting any such warranty or additional liability.
176
177 END OF TERMS AND CONDITIONS
178
179
1 [![License](https://poser.pugx.org/marcelog/PAGI/license)](https://packagist.org/packages/marcelog/PAGI)
2 [![Latest Stable Version](https://poser.pugx.org/marcelog/PAGI/v/stable)](https://packagist.org/packages/marcelog/PAGI)
3 [![Documentation Status](https://readthedocs.org/projects/pami/badge/?version=latest)](http://pami.readthedocs.org/en/latest/?badge=latest)
4
5 [![Build Status](https://travis-ci.org/marcelog/PAGI.svg)](https://travis-ci.org/marcelog/PAGI)
6 [![Coverage Status](https://coveralls.io/repos/marcelog/PAGI/badge.svg?branch=master&service=github)](https://coveralls.io/github/marcelog/PAGI?branch=master)
7 [![Code Climate](https://codeclimate.com/github/marcelog/PAGI/badges/gpa.svg)](https://codeclimate.com/github/marcelog/PAGI)
8 [![Issue Count](https://codeclimate.com/github/marcelog/PAGI/badges/issue_count.svg)](https://codeclimate.com/github/marcelog/PAGI)
9
10 # Introduction
11
12 This framework is intended to simply making ivr applications using Asterisk's
13 AGI, providing a nice level of abstraction over what an IVR should look like
14 from a developers' perspective.
15
16 Resources:
17
18 * [Main Site](http://marcelog.github.com/PAGI)
19 * [API](https://github.com/marcelog/PAGI/blob/master/doc/ApiIndex.md)
20 * [Complete PAGI/PAMI talk for the PHP Conference Argentina 2013](http://www.slideshare.net/mgornstein/phpconf-2013). Check the slide notes for the complete text :)
21 * [In-depth tutorial](http://marcelog.github.com/articles/pagi_tutorial_create_voip_telephony_application_for_asterisk_with_agi_and_php.html)
22 * [An example IVR application that includes unit tests is available here](https://github.com/marcelog/Pagi-App-And-Test-Example)
23 * [Professional Telephony Applications at hand](http://sdjournal.org/a-practical-introduction-to-functional-programming-with-php-sdj-issue-released/) The march edition of [Software Developer Journal](http://sdjournal.org/) features a complete article about writing telephony applications with PAMI and PAGI.
24
25 # Installing
26 Add this library to your [Composer](https://packagist.org/) configuration. In
27 composer.json:
28 ```json
29 "require": {
30 "marcelog/pagi": "2.*"
31 }
32 ```
33
34 # Using it
35
36 First, make sure you include the [autoloader shipped with composer](https://getcomposer.org/doc/01-basic-usage.md#autoloading):
37
38 ```php
39 require __DIR__ . '/vendor/autoload.php';
40 ```
41
42 # Quickstart
43
44 You can start by *docs/examples/quickstart* for a very basic example. You'll need something like this in your dialplan:
45
46 [default]
47 exten => 1,1,AGI(/path/to/PAGI/docs/examples/quickstart/run.sh,a,b,c,d)
48 exten => 1,n,Hangup
49
50 # Testing IVR applications
51
52 A mocked pagi client is included to easily test your ivr applications. See
53 **docs/examples/mock** to see an example of how to use it.
54
55 # Features
56
57 ## Nodes
58
59 For a tutorial about nodes, see [this article](http://marcelog.github.com/articles/pagi_node_call_flow_easy_telephony_application_for_asterisk_php.html)
60
61 Simple Call Flow Nodes are available (see **docs/examples/node/example.php**). Using
62 nodes will let you simplify how you build and test your ivr applications. Nodes
63 are an abstraction layer above the pagi client, and support:
64
65 * Prompts mixing sound files, playing numbers/digits/datetime's.
66 * Cancel and End Of Input digits.
67 * Validator callbacks for inputs, can optionally specify 1 or more sound files
68 to play when the validation fails.
69 * Callbacks for invalid and valid inputs.
70 * Optional sound when no input.
71 * Maximum valid input attempts.
72 * Optional sound when maximum attempts has been reached.
73 * Expecting at least/at most/exactly N digits per input.
74 * Timeout between digits in more-than-1 digit inputs.
75 * Timeout per input attempt.
76 * Retry Attempts for valid inputs.
77 * And much more!
78
79 The NodeController will let you control the call flow of your application, by
80 registering nodes and actions based on node results. Thus, you can jump from
81 one node to the other on cancel or complete inputs, hangup the call, execute a
82 callback, etc. For an example, see docs/examples/nodecontroller/example.php
83
84 An article about the node controller is available [here](http://marcelog.github.com/articles/making_your_ivr_nodes_call_flow_with_pagi_and_php_asterisk.html)
85
86 ## AutoDial
87
88 CallFiles are supported. You can also schedule a call in the future.
89
90 ## Fax
91
92 Sending and receiving faxes is supported using spandsp (applications SendFax
93 and ReceiveFax).
94
95 ## Available Facades
96
97 * PAGI\Client\CDR: Provided to access cdr variables.
98 * PAGI\Client\ChannelVariables: Provided to access channel variables and asterisk
99 environment variables.
100 * PAGI\Client\CallerID: Provided to access caller id variables.
101 * PAGI\Client\Result: Provided to wrap up the result for agi commands.
102 * PAGI\CallSpool\CallFile: Call file facade.
103 * PAGI\CallSpool\CallSpool: Call spool facade.
104 * PAGI\Logger\Asterisk: Provides access to asterisk logger (see logger.conf in
105 your asterisk installation).
106
107 ## Results
108
109 For every operation, a Result is provided. Some operations decorate this
110 Result to add functionality, like PlayResult, ReadResult, etc. For example,
111 a stream file will return a PlayResult, which decorates a ReadResult which
112 in turn, decorated a Result.
113
114 * PAGI\Client\DialResult
115 * PAGI\Client\ExecResult
116 * PAGI\Client\ReadResult
117 * PAGI\Client\PlayResult
118 * PAGI\Client\FaxResult
119
120 ## Debugging, logging
121
122 You can optionally set a [PSR-3](http://www.php-fig.org/psr/psr-3/) compatible logger:
123 ```php
124 $pagi->setLogger($logger);
125 ```
126
127 By default, the client will use the [NullLogger](http://www.php-fig.org/psr/psr-3/#1-4-helper-classes-and-interfaces).
128
129 # Developers
130 This project uses [phing](https://www.phing.info/). Current tasks include:
131 * test: Runs [PHPUnit](https://phpunit.de/).
132 * cs: Runs [CodeSniffer](https://github.com/squizlabs/PHP_CodeSniffer).
133 * doc: Runs [PhpDocumentor](http://www.phpdoc.org/).
134 * md: runs [PHPMD](http://phpmd.org/).
135 * build: This is the default task, and will run all the other tasks.
136
137 ## Running a phing task
138 To run a task, just do:
139
140 ```sh
141 vendor/bin/phing build
142 ```
143
144 ## Contributing
145 To contribute:
146 * Make sure you open a **concise** and **short** pull request.
147 * Throw in any needed unit tests to accomodate the new code or the
148 changes involved.
149 * Run `phing` and make sure everything is ok before submitting the pull
150 request (make phpmd and CodeSniffer happy, also make sure that phpDocumentor
151 does not throw any warnings, since all our documentation is automatically
152 generated).
153 * Your code must comply with [PSR-2](http://www.php-fig.org/psr/psr-2/),
154 CodeSniffer should take care of that.
155
156 LICENSE
157 =======
158 Copyright 2011 Marcelo Gornstein <[email protected]>
159
160 Licensed under the Apache License, Version 2.0 (the "License");
161 you may not use this file except in compliance with the License.
162 You may obtain a copy of the License at
163
164 http://www.apache.org/licenses/LICENSE-2.0
165
166 Unless required by applicable law or agreed to in writing, software
167 distributed under the License is distributed on an "AS IS" BASIS,
168 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
169 See the License for the specific language governing permissions and
170 limitations under the License.
171
1 <?xml version="1.0"?>
2 <project
3 name="php-sdk"
4 default="build"
5 basedir="."
6 description="PAGI Asterisk Gateway Interface (AGI) client for PHP">
7
8 <target name="install">
9 <exec command="./composer.phar install" checkreturn="true" passthru="true"/>
10 <exec command="./composer.phar update" checkreturn="true" passthru="true"/>
11 </target>
12
13 <target name="clean">
14 <delete dir="build"/>
15 </target>
16
17 <target name="prepare">
18 <mkdir dir="build" mode="0755"/>
19 <mkdir dir="build/doc" mode="0755"/>
20 <mkdir dir="build/doc/xml" mode="0755"/>
21 <mkdir dir="build/doc/html" mode="0755"/>
22 <mkdir dir="build/doc/md" mode="0755"/>
23 <mkdir dir="build/logs" mode="0755"/>
24 <mkdir dir="build/coverage-html" mode="0755"/>
25 </target>
26
27 <target name="cpd">
28 <exec command="vendor/bin/phpcpd --fuzzy src"
29 checkreturn="true"
30 passthru="true"/>
31 </target>
32
33 <target name="md">
34 <exec command="vendor/bin/phpmd ./src text cleancode,codesize,controversial,design,naming,unusedcode"
35 checkreturn="false"
36 passthru="true"/>
37 </target>
38
39 <target name="cs">
40 <exec command="vendor/bin/phpcs --standard=PSR2 src/*"
41 checkreturn="true"
42 passthru="true"/>
43 </target>
44
45 <target name="docxml">
46 <exec command="vendor/bin/phpdoc --template=xml -t build/doc/xml -d src --validate --sourcecode --force --log"
47 checkreturn="true"
48 passthru="true"/>
49 </target>
50
51 <target name="dochtml">
52 <exec command="vendor/bin/phpdoc -t build/doc/html -d src --validate --sourcecode --force --log"
53 checkreturn="true"
54 passthru="true"/>
55 </target>
56
57 <target name="docmd">
58 <exec dir="build/doc/md" command="../../../vendor/bin/phpdocmd ../xml/structure.xml"
59 checkreturn="true"
60 passthru="true"/>
61 <copy todir="doc" overwrite="true">
62 <fileset dir="build/doc/md">
63 <include name="*.md" />
64 </fileset>
65 </copy>
66 </target>
67
68 <target name="test">
69 <exec command="vendor/bin/phpunit -v --debug -c test/resources/phpunit.xml"
70 checkreturn="true"
71 passthru="true"/>
72 </target>
73
74 <target name="build" depends="clean, prepare, cpd, cs, md, doc, test"/>
75 <target name="doc" depends="docxml, dochtml, docmd"/>
76
77 </project>
...\ No newline at end of file ...\ No newline at end of file
1 {
2 "name": "marcelog/pagi",
3 "type": "library",
4 "description": "Asterisk Gateway Interface (AGI) client for PHP, suitable to make telephony applications using call flow nodes",
5 "keywords": ["asterisk","agi","client","call","flow","node","ivr","telephony","voip"],
6 "homepage": "http://marcelog.github.com/PAGI",
7 "license": "Apache-2.0",
8 "authors": [
9 {
10 "name": "Marcelo Gornstein",
11 "email": "[email protected]",
12 "homepage": "http://marcelog.github.com/",
13 "role": "Developer"
14 }
15 ],
16 "autoload": {
17 "psr-4": {
18 "PAGI\\": "src/PAGI"
19 }
20 },
21 "require": {
22 "php": ">=5.3.3",
23 "psr/log": ">= 1.0.0"
24 },
25 "require-dev": {
26 "phpunit/phpunit": "4.*",
27 "monolog/monolog": "1.*",
28 "squizlabs/php_codesniffer": "2.*",
29 "phpdocumentor/phpdocumentor": "2.*",
30 "phing/phing": "2.*",
31 "phpmd/phpmd": "2.*",
32 "satooshi/php-coveralls": "0.*",
33 "evert/phpdoc-md" : "~0.1.1",
34 "codeclimate/php-test-reporter": "dev-master",
35 "sebastian/phpcpd": "*"
36 }
37 }
1 API Index
2 =========
3
4 * PAGI
5 * PAGI\Application
6 * [PAGIApplication](PAGI-Application-PAGIApplication.md)
7 * PAGI\CallerId
8 * [ICallerId](PAGI-CallerId-ICallerId.md)
9 * PAGI\CallerId\Impl
10 * [CallerIdFacade](PAGI-CallerId-Impl-CallerIdFacade.md)
11 * PAGI\CallSpool
12 * [CallFile](PAGI-CallSpool-CallFile.md)
13 * PAGI\CallSpool\Exception
14 * [CallSpoolException](PAGI-CallSpool-Exception-CallSpoolException.md)
15 * [ICallSpool](PAGI-CallSpool-ICallSpool.md)
16 * PAGI\CallSpool\Impl
17 * [CallSpoolImpl](PAGI-CallSpool-Impl-CallSpoolImpl.md)
18 * PAGI\CDR
19 * [ICDR](PAGI-CDR-ICDR.md)
20 * PAGI\CDR\Impl
21 * [CDRFacade](PAGI-CDR-Impl-CDRFacade.md)
22 * PAGI\ChannelVariables
23 * [IChannelVariables](PAGI-ChannelVariables-IChannelVariables.md)
24 * PAGI\ChannelVariables\Impl
25 * [ChannelVariablesFacade](PAGI-ChannelVariables-Impl-ChannelVariablesFacade.md)
26 * PAGI\Client
27 * [AbstractClient](PAGI-Client-AbstractClient.md)
28 * [ChannelStatus](PAGI-Client-ChannelStatus.md)
29 * [IClient](PAGI-Client-IClient.md)
30 * PAGI\Client\Impl
31 * [ClientImpl](PAGI-Client-Impl-ClientImpl.md)
32 * [MockedClientImpl](PAGI-Client-Impl-MockedClientImpl.md)
33 * PAGI\Client\Result
34 * [AmdResult](PAGI-Client-Result-AmdResult.md)
35 * [DataReadResult](PAGI-Client-Result-DataReadResult.md)
36 * [DialResult](PAGI-Client-Result-DialResult.md)
37 * [DigitReadResult](PAGI-Client-Result-DigitReadResult.md)
38 * [ExecResult](PAGI-Client-Result-ExecResult.md)
39 * [FaxResult](PAGI-Client-Result-FaxResult.md)
40 * [IReadResult](PAGI-Client-Result-IReadResult.md)
41 * [IResult](PAGI-Client-Result-IResult.md)
42 * [PlayResult](PAGI-Client-Result-PlayResult.md)
43 * [ReadResultDecorator](PAGI-Client-Result-ReadResultDecorator.md)
44 * [RecordResult](PAGI-Client-Result-RecordResult.md)
45 * [Result](PAGI-Client-Result-Result.md)
46 * [ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
47 * PAGI\DialDescriptor
48 * [DAHDIDialDescriptor](PAGI-DialDescriptor-DAHDIDialDescriptor.md)
49 * [DialDescriptor](PAGI-DialDescriptor-DialDescriptor.md)
50 * [LocalDialDescriptor](PAGI-DialDescriptor-LocalDialDescriptor.md)
51 * [SIPDialDescriptor](PAGI-DialDescriptor-SIPDialDescriptor.md)
52 * PAGI\Exception
53 * [ChannelDownException](PAGI-Exception-ChannelDownException.md)
54 * [DatabaseInvalidEntryException](PAGI-Exception-DatabaseInvalidEntryException.md)
55 * [ExecuteCommandException](PAGI-Exception-ExecuteCommandException.md)
56 * [InvalidCommandException](PAGI-Exception-InvalidCommandException.md)
57 * [MockedException](PAGI-Exception-MockedException.md)
58 * [PAGIException](PAGI-Exception-PAGIException.md)
59 * [RecordException](PAGI-Exception-RecordException.md)
60 * [SoundFileException](PAGI-Exception-SoundFileException.md)
61 * PAGI\Logger
62 * PAGI\Logger\Asterisk
63 * [IAsteriskLogger](PAGI-Logger-Asterisk-IAsteriskLogger.md)
64 * PAGI\Logger\Asterisk\Impl
65 * [AsteriskLoggerImpl](PAGI-Logger-Asterisk-Impl-AsteriskLoggerImpl.md)
66 * [MockedAsteriskLoggerImpl](PAGI-Logger-Asterisk-Impl-MockedAsteriskLoggerImpl.md)
67 * PAGI\Node
68 * PAGI\Node\Exception
69 * [NodeException](PAGI-Node-Exception-NodeException.md)
70 * [MockedNode](PAGI-Node-MockedNode.md)
71 * [Node](PAGI-Node-Node.md)
72 * [NodeActionCommand](PAGI-Node-NodeActionCommand.md)
73 * [NodeController](PAGI-Node-NodeController.md)
74
1 PAGI\Application\PAGIApplication
2 ===============
3
4 Parent class for all PAGIApplications.
5
6 PHP Version 5
7
8
9 * Class name: PAGIApplication
10 * Namespace: PAGI\Application
11 * This is an **abstract** class
12
13
14
15
16
17 Properties
18 ----------
19
20
21 ### $logger
22
23 protected \PAGI\Application\Logger $logger
24
25 PSR-3 logger.
26
27
28
29 * Visibility: **protected**
30
31
32 ### $agiClient
33
34 private \PAGI\Client\IClient $agiClient
35
36 AGI Client.
37
38
39
40 * Visibility: **private**
41
42
43 Methods
44 -------
45
46
47 ### init
48
49 void PAGI\Application\PAGIApplication::init()
50
51 Called to initialize the application
52
53
54
55 * Visibility: **public**
56 * This method is **abstract**.
57
58
59
60
61 ### shutdown
62
63 void PAGI\Application\PAGIApplication::shutdown()
64
65 Called when PHPvm is shutting down.
66
67
68
69 * Visibility: **public**
70 * This method is **abstract**.
71
72
73
74
75 ### run
76
77 void PAGI\Application\PAGIApplication::run()
78
79 Called to run the application, after calling init().
80
81
82
83 * Visibility: **public**
84 * This method is **abstract**.
85
86
87
88
89 ### errorHandler
90
91 boolean PAGI\Application\PAGIApplication::errorHandler(integer $type, string $message, string $file, integer $line)
92
93 Your error handler. Be careful when implementing this one.
94
95
96
97 * Visibility: **public**
98 * This method is **abstract**.
99
100
101 #### Arguments
102 * $type **integer** - &lt;p&gt;PHP Error type constant.&lt;/p&gt;
103 * $message **string** - &lt;p&gt;Human readable error message string.&lt;/p&gt;
104 * $file **string** - &lt;p&gt;File that triggered the error.&lt;/p&gt;
105 * $line **integer** - &lt;p&gt;Line that triggered the error.&lt;/p&gt;
106
107
108
109 ### signalHandler
110
111 void PAGI\Application\PAGIApplication::signalHandler(integer $signal)
112
113 Your signal handler. Be careful when implementing this one.
114
115
116
117 * Visibility: **public**
118 * This method is **abstract**.
119
120
121 #### Arguments
122 * $signal **integer** - &lt;p&gt;Signal catched.&lt;/p&gt;
123
124
125
126 ### getAgi
127
128 \PAGI\Client\IClient PAGI\Application\PAGIApplication::getAgi()
129
130 Returns AGI Client.
131
132
133
134 * Visibility: **protected**
135
136
137
138
139 ### setLogger
140
141 void PAGI\Application\PAGIApplication::setLogger(\PAGI\Application\Psr\Log\LoggerInterface $logger)
142
143 Sets the logger implementation.
144
145
146
147 * Visibility: **public**
148
149
150 #### Arguments
151 * $logger **PAGI\Application\Psr\Log\LoggerInterface** - &lt;p&gt;The PSR3-Logger&lt;/p&gt;
152
153
154
155 ### __construct
156
157 void PAGI\Application\PAGIApplication::__construct(array $properties)
158
159 Constructor. Will call set_error_handler() and pcntl_signal() to setup
160 your errorHandler() and signalHandler(). Also will call
161 register_shutdown_function() to register your shutdown() function.
162
163
164
165 * Visibility: **public**
166
167
168 #### Arguments
169 * $properties **array** - &lt;p&gt;Optional additional properties.&lt;/p&gt;
170
171
1 PAGI\CDR\ICDR
2 ===============
3
4 CDR facade. Use this to access cdr variables.
5
6 PHP Version 5
7
8
9 * Interface name: ICDR
10 * Namespace: PAGI\CDR
11 * This is an **interface**
12
13
14
15
16
17
18 Methods
19 -------
20
21
22 ### setUserfield
23
24 void PAGI\CDR\ICDR::setUserfield(string $value)
25
26 Set userfileds for cdr. CDR(userfield).
27
28
29
30 * Visibility: **public**
31
32
33 #### Arguments
34 * $value **string** - &lt;p&gt;New userfields to use.&lt;/p&gt;
35
36
37
38 ### getUserfield
39
40 string PAGI\CDR\ICDR::getUserfield()
41
42 The channels uses specified field (read-write). CDR(userfield).
43
44
45
46 * Visibility: **public**
47
48
49
50
51 ### getUniqueId
52
53 string PAGI\CDR\ICDR::getUniqueId()
54
55 The channel uniqueid. CDR(uniqueid).
56
57
58
59 * Visibility: **public**
60
61
62
63
64 ### setAccountCode
65
66 void PAGI\CDR\ICDR::setAccountCode(string $value)
67
68 Sets account code. CDR(accountcode).
69
70
71
72 * Visibility: **public**
73
74
75 #### Arguments
76 * $value **string** - &lt;p&gt;New account code.&lt;/p&gt;
77
78
79
80 ### getAccountCode
81
82 string PAGI\CDR\ICDR::getAccountCode()
83
84 The channel account code. CDR(accountcode).
85
86
87
88 * Visibility: **public**
89
90
91
92
93 ### getAMAFlags
94
95 string PAGI\CDR\ICDR::getAMAFlags()
96
97 DOCUMENTATION, BILL, IGNORE etc. CDR(amaflags).
98
99
100
101 * Visibility: **public**
102
103
104
105
106 ### getStatus
107
108 string PAGI\CDR\ICDR::getStatus()
109
110 Call result. CDR(disposition).
111
112
113
114 * Visibility: **public**
115
116
117
118
119 ### getAnswerLength
120
121 string PAGI\CDR\ICDR::getAnswerLength()
122
123 Total answered time for the call in seconds. CDR(billsec).
124
125
126
127 * Visibility: **public**
128
129
130
131
132 ### getTotalLength
133
134 string PAGI\CDR\ICDR::getTotalLength()
135
136 Total length of the call in seconds. CDR(duration).
137
138
139
140 * Visibility: **public**
141
142
143
144
145 ### getEndTime
146
147 string PAGI\CDR\ICDR::getEndTime()
148
149 Time the call ended. CDR(end).
150
151
152
153 * Visibility: **public**
154
155
156
157
158 ### getAnswerTime
159
160 string PAGI\CDR\ICDR::getAnswerTime()
161
162 Time the call was answered. CDR(answer).
163
164
165
166 * Visibility: **public**
167
168
169
170
171 ### getStartTime
172
173 string PAGI\CDR\ICDR::getStartTime()
174
175 Time the call started. CDR(start).
176
177
178
179 * Visibility: **public**
180
181
182
183
184 ### getLastAppData
185
186 string PAGI\CDR\ICDR::getLastAppData()
187
188 Returns Last application data. CDR(lastdata).
189
190
191
192 * Visibility: **public**
193
194
195
196
197 ### getLastApp
198
199 string PAGI\CDR\ICDR::getLastApp()
200
201 Returns Last application. CDR(lastapp).
202
203
204
205 * Visibility: **public**
206
207
208
209
210 ### getChannel
211
212 string PAGI\CDR\ICDR::getChannel()
213
214 Returns origin channel. CDR(channel).
215
216
217
218 * Visibility: **public**
219
220
221
222
223 ### getDestinationChannel
224
225 string PAGI\CDR\ICDR::getDestinationChannel()
226
227 Returns destination channel. CDR(dstchannel).
228
229
230
231 * Visibility: **public**
232
233
234
235
236 ### getCallerId
237
238 string PAGI\CDR\ICDR::getCallerId()
239
240 Returns caller id. CDR(clid).
241
242
243
244 * Visibility: **public**
245
246
247
248
249 ### getSource
250
251 string PAGI\CDR\ICDR::getSource()
252
253 Returns origin. CDR(src).
254
255
256
257 * Visibility: **public**
258
259
260
261
262 ### getDestination
263
264 string PAGI\CDR\ICDR::getDestination()
265
266 Returns destination. CDR(dst).
267
268
269
270 * Visibility: **public**
271
272
273
274
275 ### getDestinationContext
276
277 string PAGI\CDR\ICDR::getDestinationContext()
278
279 Returns destination context. CDR(dcontext).
280
281
282
283 * Visibility: **public**
284
285
286
287
288 ### getCustom
289
290 string PAGI\CDR\ICDR::getCustom(string $name)
291
292 Returns a custom field in the cdr. CDR(name)
293
294
295
296 * Visibility: **public**
297
298
299 #### Arguments
300 * $name **string** - &lt;p&gt;Field name.&lt;/p&gt;
301
302
303
304 ### setCustom
305
306 void PAGI\CDR\ICDR::setCustom(string $name, string $value)
307
308 Sets a custom field in the cdr. CDR(name).
309
310
311
312 * Visibility: **public**
313
314
315 #### Arguments
316 * $name **string** - &lt;p&gt;Field name.&lt;/p&gt;
317 * $value **string** - &lt;p&gt;Field value.&lt;/p&gt;
318
319
1 PAGI\CDR\Impl\CDRFacade
2 ===============
3
4 CDR Facade.
5
6 If the channel has a cdr, that cdr record has it's own set of variables which
7 can be accessed just like channel variables. The following builtin variables
8 are available and, unless specified, read-only.
9
10 ${CDR(clid)} Caller ID
11 ${CDR(src)} Source
12 ${CDR(dst)} Destination
13 ${CDR(dcontext)} Destination context
14 ${CDR(channel)} Channel name
15 ${CDR(dstchannel)} Destination channel
16 ${CDR(lastapp)} Last app executed
17 ${CDR(lastdata)} Last app's arguments
18 ${CDR(start)} Time the call started.
19 ${CDR(answer)} Time the call was answered.
20 ${CDR(end)} Time the call ended.
21 ${CDR(duration)} Duration of the call.
22 ${CDR(billsec)} Duration of the call once it was answered.
23 ${CDR(disposition)} ANSWERED, NO ANSWER, BUSY
24 ${CDR(amaflags)} DOCUMENTATION, BILL, IGNORE etc
25 ${CDR(accountcode)} The channel's account code (read-write).
26 ${CDR(uniqueid)} The channel's unique id.
27 ${CDR(userfield)} The channels uses specified field (read-write).
28
29
30 In addition, you can set your own extra variables with a traditional
31 Set(CDR(var)=val) to anything you want.
32
33 NOTE Some CDR values (eg: duration & billsec) can't be accessed until the call
34 has terminated. As of 91617, those values will be calculated on-demand if
35 requested. Until that makes it into a stable release, you can set
36 endbeforehexten=yes in cdr.conf, and then use the "hangup" context to wrap
37 up your call.
38
39 PHP Version 5
40
41
42 * Class name: CDRFacade
43 * Namespace: PAGI\CDR\Impl
44 * This class implements: [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
45
46
47
48
49 Properties
50 ----------
51
52
53 ### $client
54
55 private \PAGI\Client\IClient $client
56
57 AGI Client, needed to access cdr data.
58
59
60
61 * Visibility: **private**
62
63
64 Methods
65 -------
66
67
68 ### setUserfield
69
70 void PAGI\CDR\ICDR::setUserfield(string $value)
71
72 Set userfileds for cdr. CDR(userfield).
73
74
75
76 * Visibility: **public**
77 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
78
79
80 #### Arguments
81 * $value **string** - &lt;p&gt;New userfields to use.&lt;/p&gt;
82
83
84
85 ### getUserfield
86
87 string PAGI\CDR\ICDR::getUserfield()
88
89 The channels uses specified field (read-write). CDR(userfield).
90
91
92
93 * Visibility: **public**
94 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
95
96
97
98
99 ### getUniqueId
100
101 string PAGI\CDR\ICDR::getUniqueId()
102
103 The channel uniqueid. CDR(uniqueid).
104
105
106
107 * Visibility: **public**
108 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
109
110
111
112
113 ### setAccountCode
114
115 void PAGI\CDR\ICDR::setAccountCode(string $value)
116
117 Sets account code. CDR(accountcode).
118
119
120
121 * Visibility: **public**
122 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
123
124
125 #### Arguments
126 * $value **string** - &lt;p&gt;New account code.&lt;/p&gt;
127
128
129
130 ### getAccountCode
131
132 string PAGI\CDR\ICDR::getAccountCode()
133
134 The channel account code. CDR(accountcode).
135
136
137
138 * Visibility: **public**
139 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
140
141
142
143
144 ### getAMAFlags
145
146 string PAGI\CDR\ICDR::getAMAFlags()
147
148 DOCUMENTATION, BILL, IGNORE etc. CDR(amaflags).
149
150
151
152 * Visibility: **public**
153 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
154
155
156
157
158 ### getStatus
159
160 string PAGI\CDR\ICDR::getStatus()
161
162 Call result. CDR(disposition).
163
164
165
166 * Visibility: **public**
167 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
168
169
170
171
172 ### getAnswerLength
173
174 string PAGI\CDR\ICDR::getAnswerLength()
175
176 Total answered time for the call in seconds. CDR(billsec).
177
178
179
180 * Visibility: **public**
181 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
182
183
184
185
186 ### getTotalLength
187
188 string PAGI\CDR\ICDR::getTotalLength()
189
190 Total length of the call in seconds. CDR(duration).
191
192
193
194 * Visibility: **public**
195 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
196
197
198
199
200 ### getEndTime
201
202 string PAGI\CDR\ICDR::getEndTime()
203
204 Time the call ended. CDR(end).
205
206
207
208 * Visibility: **public**
209 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
210
211
212
213
214 ### getAnswerTime
215
216 string PAGI\CDR\ICDR::getAnswerTime()
217
218 Time the call was answered. CDR(answer).
219
220
221
222 * Visibility: **public**
223 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
224
225
226
227
228 ### getStartTime
229
230 string PAGI\CDR\ICDR::getStartTime()
231
232 Time the call started. CDR(start).
233
234
235
236 * Visibility: **public**
237 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
238
239
240
241
242 ### getLastAppData
243
244 string PAGI\CDR\ICDR::getLastAppData()
245
246 Returns Last application data. CDR(lastdata).
247
248
249
250 * Visibility: **public**
251 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
252
253
254
255
256 ### getLastApp
257
258 string PAGI\CDR\ICDR::getLastApp()
259
260 Returns Last application. CDR(lastapp).
261
262
263
264 * Visibility: **public**
265 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
266
267
268
269
270 ### getChannel
271
272 string PAGI\CDR\ICDR::getChannel()
273
274 Returns origin channel. CDR(channel).
275
276
277
278 * Visibility: **public**
279 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
280
281
282
283
284 ### getDestinationChannel
285
286 string PAGI\CDR\ICDR::getDestinationChannel()
287
288 Returns destination channel. CDR(dstchannel).
289
290
291
292 * Visibility: **public**
293 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
294
295
296
297
298 ### getCallerId
299
300 string PAGI\CDR\ICDR::getCallerId()
301
302 Returns caller id. CDR(clid).
303
304
305
306 * Visibility: **public**
307 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
308
309
310
311
312 ### getSource
313
314 string PAGI\CDR\ICDR::getSource()
315
316 Returns origin. CDR(src).
317
318
319
320 * Visibility: **public**
321 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
322
323
324
325
326 ### getDestination
327
328 string PAGI\CDR\ICDR::getDestination()
329
330 Returns destination. CDR(dst).
331
332
333
334 * Visibility: **public**
335 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
336
337
338
339
340 ### getDestinationContext
341
342 string PAGI\CDR\ICDR::getDestinationContext()
343
344 Returns destination context. CDR(dcontext).
345
346
347
348 * Visibility: **public**
349 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
350
351
352
353
354 ### getCustom
355
356 string PAGI\CDR\ICDR::getCustom(string $name)
357
358 Returns a custom field in the cdr. CDR(name)
359
360
361
362 * Visibility: **public**
363 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
364
365
366 #### Arguments
367 * $name **string** - &lt;p&gt;Field name.&lt;/p&gt;
368
369
370
371 ### setCustom
372
373 void PAGI\CDR\ICDR::setCustom(string $name, string $value)
374
375 Sets a custom field in the cdr. CDR(name).
376
377
378
379 * Visibility: **public**
380 * This method is defined by [PAGI\CDR\ICDR](PAGI-CDR-ICDR.md)
381
382
383 #### Arguments
384 * $name **string** - &lt;p&gt;Field name.&lt;/p&gt;
385 * $value **string** - &lt;p&gt;Field value.&lt;/p&gt;
386
387
388
389 ### getCDRVariable
390
391 string PAGI\CDR\Impl\CDRFacade::getCDRVariable(string $name)
392
393 Access AGI client to get the variables.
394
395
396
397 * Visibility: **protected**
398
399
400 #### Arguments
401 * $name **string** - &lt;p&gt;Variable name.&lt;/p&gt;
402
403
404
405 ### setCDRVariable
406
407 void PAGI\CDR\Impl\CDRFacade::setCDRVariable(string $name, string $value)
408
409 Access AGI client to set the variable.
410
411
412
413 * Visibility: **protected**
414
415
416 #### Arguments
417 * $name **string** - &lt;p&gt;Variable name.&lt;/p&gt;
418 * $value **string** - &lt;p&gt;Value.&lt;/p&gt;
419
420
421
422 ### __construct
423
424 void PAGI\CDR\Impl\CDRFacade::__construct(\PAGI\Client\IClient $client)
425
426 Constructor.
427
428
429
430 * Visibility: **public**
431
432
433 #### Arguments
434 * $client **[PAGI\Client\IClient](PAGI-Client-IClient.md)** - &lt;p&gt;AGI Client.&lt;/p&gt;
435
436
1 PAGI\CallSpool\CallFile
2 ===============
3
4 A call file facade.
5
6 PHP Version 5
7
8
9 * Class name: CallFile
10 * Namespace: PAGI\CallSpool
11
12
13
14
15
16 Properties
17 ----------
18
19
20 ### $parameters
21
22 private array<mixed,string> $parameters
23
24 Parameters.
25
26
27
28 * Visibility: **private**
29
30
31 ### $variables
32
33 private array<mixed,string> $variables
34
35 Variables.
36
37
38
39 * Visibility: **private**
40
41
42 Methods
43 -------
44
45
46 ### getParameter
47
48 string PAGI\CallSpool\CallFile::getParameter(string $key)
49
50 Returns the value for the given parameter.
51
52
53
54 * Visibility: **protected**
55
56
57 #### Arguments
58 * $key **string** - &lt;p&gt;Parameter name.&lt;/p&gt;
59
60
61
62 ### setParameter
63
64 void PAGI\CallSpool\CallFile::setParameter(string $key, string $value)
65
66 Sets a given parameter with the given value.
67
68
69
70 * Visibility: **protected**
71
72
73 #### Arguments
74 * $key **string** - &lt;p&gt;Parameter name.&lt;/p&gt;
75 * $value **string** - &lt;p&gt;Value.&lt;/p&gt;
76
77
78
79 ### getVariable
80
81 string PAGI\CallSpool\CallFile::getVariable(string $key)
82
83 Returns the value for the given variable.
84
85
86
87 * Visibility: **public**
88
89
90 #### Arguments
91 * $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
92
93
94
95 ### setVariable
96
97 void PAGI\CallSpool\CallFile::setVariable(string $key, string $value)
98
99 Sets a given variable with the given value.
100
101
102
103 * Visibility: **public**
104
105
106 #### Arguments
107 * $key **string** - &lt;p&gt;Variable name.&lt;/p&gt;
108 * $value **string** - &lt;p&gt;Value.&lt;/p&gt;
109
110
111
112 ### getChannel
113
114 string PAGI\CallSpool\CallFile::getChannel()
115
116 Returns channel to use for the call.
117
118
119
120 * Visibility: **public**
121
122
123
124
125 ### getCallerId
126
127 string PAGI\CallSpool\CallFile::getCallerId()
128
129 Returns Caller ID, Please note: It may not work if you do not respect
130 the format: CallerID: "Some Name" <1234>
131
132
133
134 * Visibility: **public**
135
136
137
138
139 ### setCallerId
140
141 void PAGI\CallSpool\CallFile::setCallerId(string $value)
142
143 Sets the Caller ID, Please note: It may not work if you do not respect
144 the format: CallerID: "Some Name" <1234>
145
146
147
148 * Visibility: **public**
149
150
151 #### Arguments
152 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
153
154
155
156 ### getWaitTime
157
158 integer PAGI\CallSpool\CallFile::getWaitTime()
159
160 Returns seconds to wait for an answer. Default is 45.
161
162
163
164 * Visibility: **public**
165
166
167
168
169 ### setWaitTime
170
171 void PAGI\CallSpool\CallFile::setWaitTime(integer $value)
172
173 Sets seconds to wait for an answer. Default is 45.
174
175
176
177 * Visibility: **public**
178
179
180 #### Arguments
181 * $value **integer** - &lt;p&gt;Value to set.&lt;/p&gt;
182
183
184
185 ### getMaxRetries
186
187 integer PAGI\CallSpool\CallFile::getMaxRetries()
188
189 Returns number of retries before failing (not including the initial
190 attempt, e.g. 0 = total of 1 attempt to make the call). Default is 0.
191
192
193
194 * Visibility: **public**
195
196
197
198
199 ### setMaxRetries
200
201 void PAGI\CallSpool\CallFile::setMaxRetries(integer $value)
202
203 Sets number of retries before failing (not including the initial
204 attempt, e.g. 0 = total of 1 attempt to make the call). Default is 0.
205
206
207
208 * Visibility: **public**
209
210
211 #### Arguments
212 * $value **integer** - &lt;p&gt;Value to set.&lt;/p&gt;
213
214
215
216 ### getRetryTime
217
218 integer PAGI\CallSpool\CallFile::getRetryTime()
219
220 Returns seconds between retries, Don't hammer an unavailable phone.
221
222 Default is 300 (5 min).
223
224 * Visibility: **public**
225
226
227
228
229 ### setRetryTime
230
231 void PAGI\CallSpool\CallFile::setRetryTime(integer $value)
232
233 Sets seconds between retries, Don't hammer an unavailable phone.
234
235 Default is 300 (5 min).
236
237 * Visibility: **public**
238
239
240 #### Arguments
241 * $value **integer** - &lt;p&gt;Value to set.&lt;/p&gt;
242
243
244
245 ### getAccount
246
247 string PAGI\CallSpool\CallFile::getAccount()
248
249 Returns account code to use for this call.
250
251
252
253 * Visibility: **public**
254
255
256
257
258 ### setAccount
259
260 void PAGI\CallSpool\CallFile::setAccount(string $value)
261
262 Sets account code to use for this call.
263
264
265
266 * Visibility: **public**
267
268
269 #### Arguments
270 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
271
272
273
274 ### getContext
275
276 string PAGI\CallSpool\CallFile::getContext()
277
278 Returns context to use for this call when answered.
279
280
281
282 * Visibility: **public**
283
284
285
286
287 ### setContext
288
289 void PAGI\CallSpool\CallFile::setContext(string $value)
290
291 Sets context to use for this call when answered.
292
293
294
295 * Visibility: **public**
296
297
298 #### Arguments
299 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
300
301
302
303 ### getPriority
304
305 string PAGI\CallSpool\CallFile::getPriority()
306
307 Returns priority to use for this call when answered.
308
309
310
311 * Visibility: **public**
312
313
314
315
316 ### setPriority
317
318 void PAGI\CallSpool\CallFile::setPriority(string $value)
319
320 Sets priority to use for this call when answered.
321
322
323
324 * Visibility: **public**
325
326
327 #### Arguments
328 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
329
330
331
332 ### getExtension
333
334 string PAGI\CallSpool\CallFile::getExtension()
335
336 Returns extension to use for this call when answered.
337
338
339
340 * Visibility: **public**
341
342
343
344
345 ### setExtension
346
347 void PAGI\CallSpool\CallFile::setExtension(string $value)
348
349 Sets extension to use for this call when answered.
350
351
352
353 * Visibility: **public**
354
355
356 #### Arguments
357 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
358
359
360
361 ### getApplication
362
363 string PAGI\CallSpool\CallFile::getApplication()
364
365 Returns Asterisk Application to run (use instead of specifiying context,
366 extension and priority)
367
368
369
370 * Visibility: **public**
371
372
373
374
375 ### setApplication
376
377 void PAGI\CallSpool\CallFile::setApplication(string $value)
378
379 Sets Asterisk Application to run (use instead of specifiying context,
380 extension and priority)
381
382
383
384 * Visibility: **public**
385
386
387 #### Arguments
388 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
389
390
391
392 ### getApplicationData
393
394 string PAGI\CallSpool\CallFile::getApplicationData()
395
396 Returns the options to be passed to application.
397
398
399
400 * Visibility: **public**
401
402
403
404
405 ### setApplicationData
406
407 void PAGI\CallSpool\CallFile::setApplicationData(array $options)
408
409 Sets the options to be passed to application.
410
411
412
413 * Visibility: **public**
414
415
416 #### Arguments
417 * $options **array**
418
419
420
421 ### getAlwaysDelete
422
423 boolean PAGI\CallSpool\CallFile::getAlwaysDelete()
424
425 If the file's modification time is in the future, the call file will not
426 be deleted
427
428
429
430 * Visibility: **public**
431
432
433
434
435 ### setAlwaysDelete
436
437 void PAGI\CallSpool\CallFile::setAlwaysDelete(boolean $value)
438
439 If the file's modification time is in the future, the call file will not
440 be deleted
441
442
443
444 * Visibility: **public**
445
446
447 #### Arguments
448 * $value **boolean** - &lt;p&gt;Value to set.&lt;/p&gt;
449
450
451
452 ### getArchive
453
454 boolean PAGI\CallSpool\CallFile::getArchive()
455
456 Sets if should move to subdir "outgoing_done" with "Status: value",
457 where value can be Completed, Expired or Failed.
458
459
460
461 * Visibility: **public**
462
463
464
465
466 ### setArchive
467
468 void PAGI\CallSpool\CallFile::setArchive(boolean $value)
469
470 Sets if should move to subdir "outgoing_done" with "Status: value",
471 where value can be Completed, Expired or Failed.
472
473
474
475 * Visibility: **public**
476
477
478 #### Arguments
479 * $value **boolean** - &lt;p&gt;Value to set.&lt;/p&gt;
480
481
482
483 ### serialize
484
485 string PAGI\CallSpool\CallFile::serialize()
486
487 Returns the text describing this call file, ready to be spooled.
488
489
490
491 * Visibility: **public**
492
493
494
495
496 ### unserialize
497
498 void PAGI\CallSpool\CallFile::unserialize(string $text)
499
500 Deconstructs a call file from the given text.
501
502
503
504 * Visibility: **public**
505
506
507 #### Arguments
508 * $text **string** - &lt;p&gt;A call file (intended to be pre-loaded, with
509 file_get_contents() or similar).&lt;/p&gt;
510
511
512
513 ### __construct
514
515 void PAGI\CallSpool\CallFile::__construct(\PAGI\DialDescriptor\DialDescriptor $dialDescriptor)
516
517 Constructor.
518
519
520
521 * Visibility: **public**
522
523
524 #### Arguments
525 * $dialDescriptor **[PAGI\DialDescriptor\DialDescriptor](PAGI-DialDescriptor-DialDescriptor.md)**
526
527
1 PAGI\CallSpool\Exception\CallSpoolException
2 ===============
3
4 This exception indicates an error related to the call spool.
5
6 PHP Version 5
7
8
9 * Class name: CallSpoolException
10 * Namespace: PAGI\CallSpool\Exception
11 * Parent class: [PAGI\Exception\PAGIException](PAGI-Exception-PAGIException.md)
12
13
14
15
16
17
18
19
1 PAGI\CallSpool\ICallSpool
2 ===============
3
4 An interface to access asterisk call spool.
5
6 PHP Version 5
7
8
9 * Interface name: ICallSpool
10 * Namespace: PAGI\CallSpool
11 * This is an **interface**
12
13
14
15
16
17
18 Methods
19 -------
20
21
22 ### spool
23
24 void PAGI\CallSpool\ICallSpool::spool(\PAGI\CallSpool\CallFile $call, integer $schedule)
25
26 Spools the given call.
27
28
29
30 * Visibility: **public**
31
32
33 #### Arguments
34 * $call **[PAGI\CallSpool\CallFile](PAGI-CallSpool-CallFile.md)** - &lt;p&gt;Call to spool.&lt;/p&gt;
35 * $schedule **integer** - &lt;p&gt;Optional unix timestamp to schedule the call.&lt;/p&gt;
36
37
1 PAGI\CallSpool\Impl\CallSpoolImpl
2 ===============
3
4 An implementation for asterisk call spool.
5
6 PHP Version 5
7
8
9 * Class name: CallSpoolImpl
10 * Namespace: PAGI\CallSpool\Impl
11 * This class implements: [PAGI\CallSpool\ICallSpool](PAGI-CallSpool-ICallSpool.md)
12
13
14
15
16 Properties
17 ----------
18
19
20 ### $tmpDir
21
22 private string $tmpDir = '/tmp'
23
24 Where to temporary generate call files.
25
26
27
28 * Visibility: **private**
29
30
31 ### $spoolDir
32
33 private string $spoolDir = '/var/spool/asterisk'
34
35 Asterisk spool directory.
36
37
38
39 * Visibility: **private**
40
41
42 ### $instance
43
44 private \PAGI\CallSpool\Impl\CallSpoolImpl $instance = false
45
46 Current instance.
47
48
49
50 * Visibility: **private**
51 * This property is **static**.
52
53
54 Methods
55 -------
56
57
58 ### getInstance
59
60 \PAGI\CallSpool\Impl\CallSpoolImpl PAGI\CallSpool\Impl\CallSpoolImpl::getInstance(array<mixed,string> $options)
61
62 Returns an instance for this spool/
63
64
65
66 * Visibility: **public**
67 * This method is **static**.
68
69
70 #### Arguments
71 * $options **array&lt;mixed,string&gt;** - &lt;p&gt;Configuration options.&lt;/p&gt;
72
73
74
75 ### spool
76
77 void PAGI\CallSpool\ICallSpool::spool(\PAGI\CallSpool\CallFile $call, integer $schedule)
78
79 Spools the given call.
80
81
82
83 * Visibility: **public**
84 * This method is defined by [PAGI\CallSpool\ICallSpool](PAGI-CallSpool-ICallSpool.md)
85
86
87 #### Arguments
88 * $call **[PAGI\CallSpool\CallFile](PAGI-CallSpool-CallFile.md)** - &lt;p&gt;Call to spool.&lt;/p&gt;
89 * $schedule **integer** - &lt;p&gt;Optional unix timestamp to schedule the call.&lt;/p&gt;
90
91
92
93 ### __construct
94
95 void PAGI\CallSpool\Impl\CallSpoolImpl::__construct(array<mixed,string> $options)
96
97 Constructor.
98
99
100
101 * Visibility: **private**
102
103
104 #### Arguments
105 * $options **array&lt;mixed,string&gt;** - &lt;p&gt;Options for this spool.&lt;/p&gt;
106
107
1 PAGI\CallerId\ICallerId
2 ===============
3
4 AGI Caller id facade.
5
6 PHP Version 5
7
8
9 * Interface name: ICallerId
10 * Namespace: PAGI\CallerId
11 * This is an **interface**
12
13
14
15
16
17
18 Methods
19 -------
20
21
22 ### setANI
23
24 void PAGI\CallerId\ICallerId::setANI(string $value)
25
26 Sets caller id ani. CALLERID(ani).
27
28
29
30 * Visibility: **public**
31
32
33 #### Arguments
34 * $value **string** - &lt;p&gt;ANI.&lt;/p&gt;
35
36
37
38 ### getANI
39
40 string PAGI\CallerId\ICallerId::getANI()
41
42 Returns caller id ani. CALLERID(ani)
43
44
45
46 * Visibility: **public**
47
48
49
50
51 ### setDNID
52
53 void PAGI\CallerId\ICallerId::setDNID(string $value)
54
55 Sets caller id dnid. CALLERID(dnid)
56
57
58
59 * Visibility: **public**
60
61
62 #### Arguments
63 * $value **string** - &lt;p&gt;DNID.&lt;/p&gt;
64
65
66
67 ### getDNID
68
69 string PAGI\CallerId\ICallerId::getDNID()
70
71 Returns caller id dnid. CALLERID(dnid)
72
73
74
75 * Visibility: **public**
76
77
78
79
80 ### setRDNIS
81
82 void PAGI\CallerId\ICallerId::setRDNIS(string $value)
83
84 Sets caller id rdnis. CALLERID(rdnis)
85
86
87
88 * Visibility: **public**
89
90
91 #### Arguments
92 * $value **string** - &lt;p&gt;RDNIS.&lt;/p&gt;
93
94
95
96 ### getRDNIS
97
98 string PAGI\CallerId\ICallerId::getRDNIS()
99
100 Returns caller id rdnis. CALLERID(rdnis)
101
102
103
104 * Visibility: **public**
105
106
107
108
109 ### setName
110
111 void PAGI\CallerId\ICallerId::setName(string $value)
112
113 Sets caller id name. CALLERID(name)
114
115
116
117 * Visibility: **public**
118
119
120 #### Arguments
121 * $value **string** - &lt;p&gt;Name.&lt;/p&gt;
122
123
124
125 ### getName
126
127 string PAGI\CallerId\ICallerId::getName()
128
129 Returns caller id name. CALLERID(name)
130
131
132
133 * Visibility: **public**
134
135
136
137
138 ### getNumber
139
140 string PAGI\CallerId\ICallerId::getNumber()
141
142 Returns caller id number. CALLERID(num)
143
144
145
146 * Visibility: **public**
147
148
149
150
151 ### setNumber
152
153 void PAGI\CallerId\ICallerId::setNumber(string $value)
154
155 Sets caller id number. CALLERID(num)
156
157
158
159 * Visibility: **public**
160
161
162 #### Arguments
163 * $value **string** - &lt;p&gt;Number.&lt;/p&gt;
164
165
166
167 ### setCallerPres
168
169 void PAGI\CallerId\ICallerId::setCallerPres(string $presentationMode)
170
171 Changes the caller id presentation mode.
172
173
174
175 * Visibility: **public**
176
177
178 #### Arguments
179 * $presentationMode **string** - &lt;p&gt;Can be one of:
180 allowed_not_screened - Presentation Allowed, Not Screened.
181 allowed_passed_screen - Presentation Allowed, Passed Screen.
182 allowed_failed_screen - Presentation Allowed, Failed Screen.
183 allowed - Presentation Allowed, Network Number.
184 prohib_not_screened - Presentation Prohibited, Not Screened.
185 prohib_passed_screen - Presentation Prohibited, Passed Screen.
186 prohib_failed_screen - Presentation Prohibited, Failed Screen.
187 prohib - Presentation Prohibited, Network Number.
188 unavailable - Number Unavailable.&lt;/p&gt;
189
190
1 PAGI\CallerId\Impl\CallerIdFacade
2 ===============
3
4 AGI Caller id facade.
5
6 PHP Version 5
7
8
9 * Class name: CallerIdFacade
10 * Namespace: PAGI\CallerId\Impl
11 * This class implements: [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
12
13
14
15
16 Properties
17 ----------
18
19
20 ### $client
21
22 private \PAGI\Client\IClient $client
23
24 Instance of client to access caller id variables.
25
26
27
28 * Visibility: **private**
29
30
31 Methods
32 -------
33
34
35 ### setANI
36
37 void PAGI\CallerId\ICallerId::setANI(string $value)
38
39 Sets caller id ani. CALLERID(ani).
40
41
42
43 * Visibility: **public**
44 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
45
46
47 #### Arguments
48 * $value **string** - &lt;p&gt;ANI.&lt;/p&gt;
49
50
51
52 ### getANI
53
54 string PAGI\CallerId\ICallerId::getANI()
55
56 Returns caller id ani. CALLERID(ani)
57
58
59
60 * Visibility: **public**
61 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
62
63
64
65
66 ### setDNID
67
68 void PAGI\CallerId\ICallerId::setDNID(string $value)
69
70 Sets caller id dnid. CALLERID(dnid)
71
72
73
74 * Visibility: **public**
75 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
76
77
78 #### Arguments
79 * $value **string** - &lt;p&gt;DNID.&lt;/p&gt;
80
81
82
83 ### getDNID
84
85 string PAGI\CallerId\ICallerId::getDNID()
86
87 Returns caller id dnid. CALLERID(dnid)
88
89
90
91 * Visibility: **public**
92 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
93
94
95
96
97 ### setRDNIS
98
99 void PAGI\CallerId\ICallerId::setRDNIS(string $value)
100
101 Sets caller id rdnis. CALLERID(rdnis)
102
103
104
105 * Visibility: **public**
106 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
107
108
109 #### Arguments
110 * $value **string** - &lt;p&gt;RDNIS.&lt;/p&gt;
111
112
113
114 ### getRDNIS
115
116 string PAGI\CallerId\ICallerId::getRDNIS()
117
118 Returns caller id rdnis. CALLERID(rdnis)
119
120
121
122 * Visibility: **public**
123 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
124
125
126
127
128 ### setName
129
130 void PAGI\CallerId\ICallerId::setName(string $value)
131
132 Sets caller id name. CALLERID(name)
133
134
135
136 * Visibility: **public**
137 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
138
139
140 #### Arguments
141 * $value **string** - &lt;p&gt;Name.&lt;/p&gt;
142
143
144
145 ### getName
146
147 string PAGI\CallerId\ICallerId::getName()
148
149 Returns caller id name. CALLERID(name)
150
151
152
153 * Visibility: **public**
154 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
155
156
157
158
159 ### getNumber
160
161 string PAGI\CallerId\ICallerId::getNumber()
162
163 Returns caller id number. CALLERID(num)
164
165
166
167 * Visibility: **public**
168 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
169
170
171
172
173 ### setNumber
174
175 void PAGI\CallerId\ICallerId::setNumber(string $value)
176
177 Sets caller id number. CALLERID(num)
178
179
180
181 * Visibility: **public**
182 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
183
184
185 #### Arguments
186 * $value **string** - &lt;p&gt;Number.&lt;/p&gt;
187
188
189
190 ### getCallerIdVariable
191
192 string PAGI\CallerId\Impl\CallerIdFacade::getCallerIdVariable(string $name)
193
194 Access AGI client to get the variables.
195
196
197
198 * Visibility: **protected**
199
200
201 #### Arguments
202 * $name **string** - &lt;p&gt;Variable name.&lt;/p&gt;
203
204
205
206 ### setCallerIdVariable
207
208 void PAGI\CallerId\Impl\CallerIdFacade::setCallerIdVariable(string $name, string $value)
209
210 Access AGI client to set the variable.
211
212
213
214 * Visibility: **protected**
215
216
217 #### Arguments
218 * $name **string** - &lt;p&gt;Variable name.&lt;/p&gt;
219 * $value **string** - &lt;p&gt;Value.&lt;/p&gt;
220
221
222
223 ### setCallerPres
224
225 void PAGI\CallerId\ICallerId::setCallerPres(string $presentationMode)
226
227 Changes the caller id presentation mode.
228
229
230
231 * Visibility: **public**
232 * This method is defined by [PAGI\CallerId\ICallerId](PAGI-CallerId-ICallerId.md)
233
234
235 #### Arguments
236 * $presentationMode **string** - &lt;p&gt;Can be one of:
237 allowed_not_screened - Presentation Allowed, Not Screened.
238 allowed_passed_screen - Presentation Allowed, Passed Screen.
239 allowed_failed_screen - Presentation Allowed, Failed Screen.
240 allowed - Presentation Allowed, Network Number.
241 prohib_not_screened - Presentation Prohibited, Not Screened.
242 prohib_passed_screen - Presentation Prohibited, Passed Screen.
243 prohib_failed_screen - Presentation Prohibited, Failed Screen.
244 prohib - Presentation Prohibited, Network Number.
245 unavailable - Number Unavailable.&lt;/p&gt;
246
247
248
249 ### __toString
250
251 string PAGI\CallerId\Impl\CallerIdFacade::__toString()
252
253 Standard procedure.
254
255
256
257 * Visibility: **public**
258
259
260
261
262 ### __construct
263
264 void PAGI\CallerId\Impl\CallerIdFacade::__construct(\PAGI\Client\IClient $client)
265
266 Constructor.
267
268
269
270 * Visibility: **public**
271
272
273 #### Arguments
274 * $client **[PAGI\Client\IClient](PAGI-Client-IClient.md)** - &lt;p&gt;AGI Client to use.&lt;/p&gt;
275
276
1 PAGI\ChannelVariables\IChannelVariables
2 ===============
3
4 ChannelVariables facade. Use this to access channel variables.
5
6 PHP Version 5
7
8
9 * Interface name: IChannelVariables
10 * Namespace: PAGI\ChannelVariables
11 * This is an **interface**
12
13
14
15
16
17
18 Methods
19 -------
20
21
22 ### getChannel
23
24 string PAGI\ChannelVariables\IChannelVariables::getChannel()
25
26 Returns channel (agi_channel).
27
28
29
30 * Visibility: **public**
31
32
33
34
35 ### getLanguage
36
37 string PAGI\ChannelVariables\IChannelVariables::getLanguage()
38
39 Returns language (agi_language).
40
41
42
43 * Visibility: **public**
44
45
46
47
48 ### getType
49
50 string PAGI\ChannelVariables\IChannelVariables::getType()
51
52 Returns channel type (agi_type).
53
54
55
56 * Visibility: **public**
57
58
59
60
61 ### getUniqueId
62
63 string PAGI\ChannelVariables\IChannelVariables::getUniqueId()
64
65 Returns channel uniqueid (agi_uniqueid).
66
67
68
69 * Visibility: **public**
70
71
72
73
74 ### getVersion
75
76 string PAGI\ChannelVariables\IChannelVariables::getVersion()
77
78 Returns asterisk version (agi_version).
79
80
81
82 * Visibility: **public**
83
84
85
86
87 ### getCallerId
88
89 string PAGI\ChannelVariables\IChannelVariables::getCallerId()
90
91 Returns caller id number (agi_callerid).
92
93
94
95 * Visibility: **public**
96
97
98
99
100 ### getCallerIdName
101
102 string PAGI\ChannelVariables\IChannelVariables::getCallerIdName()
103
104 Returns caller id name (agi_calleridname).
105
106
107
108 * Visibility: **public**
109
110
111
112
113 ### getCallingPres
114
115 string PAGI\ChannelVariables\IChannelVariables::getCallingPres()
116
117 Returns CallingPres (agi_callingpres).
118
119
120
121 * Visibility: **public**
122
123
124
125
126 ### getCallingAni2
127
128 string PAGI\ChannelVariables\IChannelVariables::getCallingAni2()
129
130 Returns CallingAni (agi_callingani2).
131
132
133
134 * Visibility: **public**
135
136
137
138
139 ### getCallingTon
140
141 string PAGI\ChannelVariables\IChannelVariables::getCallingTon()
142
143 Returns CallingTon (agi_callington).
144
145
146
147 * Visibility: **public**
148
149
150
151
152 ### getCallingTns
153
154 string PAGI\ChannelVariables\IChannelVariables::getCallingTns()
155
156 Returns CallingTns (agi_callingtns).
157
158
159
160 * Visibility: **public**
161
162
163
164
165 ### getDNID
166
167 string PAGI\ChannelVariables\IChannelVariables::getDNID()
168
169 Returns DNID (agi_dnid).
170
171
172
173 * Visibility: **public**
174
175
176
177
178 ### getContext
179
180 string PAGI\ChannelVariables\IChannelVariables::getContext()
181
182 Returns context (agi_context).
183
184
185
186 * Visibility: **public**
187
188
189
190
191 ### getRDNIS
192
193 string PAGI\ChannelVariables\IChannelVariables::getRDNIS()
194
195 Returns RDNIS (agi_rdnis).
196
197
198
199 * Visibility: **public**
200
201
202
203
204 ### getRequest
205
206 string PAGI\ChannelVariables\IChannelVariables::getRequest()
207
208 Returns agi requested (agi_request).
209
210
211
212 * Visibility: **public**
213
214
215
216
217 ### getDNIS
218
219 string PAGI\ChannelVariables\IChannelVariables::getDNIS()
220
221 Returns extension dialed (dnis) (agi_extension).
222
223
224
225 * Visibility: **public**
226
227
228
229
230 ### getThreadId
231
232 string PAGI\ChannelVariables\IChannelVariables::getThreadId()
233
234 Returns thread id (agi_threadid).
235
236
237
238 * Visibility: **public**
239
240
241
242
243 ### getAccountCode
244
245 string PAGI\ChannelVariables\IChannelVariables::getAccountCode()
246
247 Returns account code (agi_accountcode).
248
249
250
251 * Visibility: **public**
252
253
254
255
256 ### getEnhanced
257
258 string PAGI\ChannelVariables\IChannelVariables::getEnhanced()
259
260 Returns if using enhanced (agi_enhanced).
261
262
263
264 * Visibility: **public**
265
266
267
268
269 ### getPriority
270
271 string PAGI\ChannelVariables\IChannelVariables::getPriority()
272
273 Returns context priority (agi_priority).
274
275
276
277 * Visibility: **public**
278
279
280
281
282 ### getTotalArguments
283
284 integer PAGI\ChannelVariables\IChannelVariables::getTotalArguments()
285
286 Returns total number of agi arguments.
287
288
289
290 * Visibility: **public**
291
292
293
294
295 ### getArgument
296
297 string PAGI\ChannelVariables\IChannelVariables::getArgument(integer $index)
298
299 Returns the given agi argument. (agi_arg_N).
300
301
302
303 * Visibility: **public**
304
305
306 #### Arguments
307 * $index **integer** - &lt;p&gt;Argument number, starting with 0.&lt;/p&gt;
308
309
310
311 ### getArguments
312
313 array<mixed,string> PAGI\ChannelVariables\IChannelVariables::getArguments()
314
315 Returns all arguments as an array.
316
317
318
319 * Visibility: **public**
320
321
322
323
324 ### getDirectoryConfig
325
326 string PAGI\ChannelVariables\IChannelVariables::getDirectoryConfig()
327
328 Returns the config directory for this running version of asterisk.
329
330 Uses environment variable AST_CONFIG_DIR.
331
332 * Visibility: **public**
333
334
335
336
337 ### getConfigFile
338
339 string PAGI\ChannelVariables\IChannelVariables::getConfigFile()
340
341 Returns the config file for this running version of asterisk.
342
343 Uses environment variable AST_CONFIG_FILE.
344
345 * Visibility: **public**
346
347
348
349
350 ### getDirectoryModules
351
352 string PAGI\ChannelVariables\IChannelVariables::getDirectoryModules()
353
354 Returns the modules directory for this running version of asterisk.
355
356 Uses environment variable AST_MODULE_DIR.
357
358 * Visibility: **public**
359
360
361
362
363 ### getDirectorySpool
364
365 string PAGI\ChannelVariables\IChannelVariables::getDirectorySpool()
366
367 Returns the spool directory for this running version of asterisk.
368
369 Uses environment variable AST_SPOOL_DIR.
370
371 * Visibility: **public**
372
373
374
375
376 ### getDirectoryMonitor
377
378 string PAGI\ChannelVariables\IChannelVariables::getDirectoryMonitor()
379
380 Returns the monitor directory for this running version of asterisk.
381
382 Uses environment variable AST_MONITOR_DIR.
383
384 * Visibility: **public**
385
386
387
388
389 ### getDirectoryVar
390
391 string PAGI\ChannelVariables\IChannelVariables::getDirectoryVar()
392
393 Returns the var directory for this running version of asterisk.
394
395 Uses environment variable AST_VAR_DIR.
396
397 * Visibility: **public**
398
399
400
401
402 ### getDirectoryData
403
404 string PAGI\ChannelVariables\IChannelVariables::getDirectoryData()
405
406 Returns the data directory for this running version of asterisk.
407
408 Uses environment variable AST_DATA_DIR.
409
410 * Visibility: **public**
411
412
413
414
415 ### getDirectoryLog
416
417 string PAGI\ChannelVariables\IChannelVariables::getDirectoryLog()
418
419 Returns the log directory for this running version of asterisk.
420
421 Uses environment variable AST_LOG_DIR.
422
423 * Visibility: **public**
424
425
426
427
428 ### getDirectoryAgi
429
430 string PAGI\ChannelVariables\IChannelVariables::getDirectoryAgi()
431
432 Returns the agi directory for this running version of asterisk.
433
434 Uses environment variable AST_AGI_DIR.
435
436 * Visibility: **public**
437
438
439
440
441 ### getDirectoryKey
442
443 string PAGI\ChannelVariables\IChannelVariables::getDirectoryKey()
444
445 Returns the key directory for this running version of asterisk.
446
447 Uses environment variable AST_KEY_DIR.
448
449 * Visibility: **public**
450
451
452
453
454 ### getDirectoryRun
455
456 string PAGI\ChannelVariables\IChannelVariables::getDirectoryRun()
457
458 Returns the run directory for this running version of asterisk.
459
460 Uses environment variable AST_RUN_DIR.
461
462 * Visibility: **public**
463
464
465
1 PAGI\Client\ChannelStatus
2 ===============
3
4 ChannelStatus &#039;Helper&#039;. See: http://www.voip-info.org/wiki/view/channel+status
5
6 PHP Version 5
7
8
9 * Class name: ChannelStatus
10 * Namespace: PAGI\Client
11
12
13
14 Constants
15 ----------
16
17
18 ### DOWN_AVAILABLE
19
20 const DOWN_AVAILABLE = 0
21
22
23
24
25
26 ### DOWN_RESERVED
27
28 const DOWN_RESERVED = 1
29
30
31
32
33
34 ### OFF_HOOK
35
36 const OFF_HOOK = 2
37
38
39
40
41
42 ### DIGITS_DIALED
43
44 const DIGITS_DIALED = 3
45
46
47
48
49
50 ### LINE_RINGING
51
52 const LINE_RINGING = 4
53
54
55
56
57
58 ### REMOTE_RINGING
59
60 const REMOTE_RINGING = 5
61
62
63
64
65
66 ### LINE_UP
67
68 const LINE_UP = 6
69
70
71
72
73
74 ### LINE_BUSY
75
76 const LINE_BUSY = 7
77
78
79
80
81
82
83
84 Methods
85 -------
86
87
88 ### toString
89
90 string PAGI\Client\ChannelStatus::toString(integer $status)
91
92 This will return the human readable description for the given channel
93 status. See class constants. (False if the status is invalid).
94
95
96
97 * Visibility: **public**
98 * This method is **static**.
99
100
101 #### Arguments
102 * $status **integer** - &lt;p&gt;Channel status.&lt;/p&gt;
103
104
1 PAGI\Client\Result\AmdResult
2 ===============
3
4 This decorated result adds the functionality to check for an AMD result.
5
6 PHP Version 5
7
8
9 * Class name: AmdResult
10 * Namespace: PAGI\Client\Result
11 * Parent class: [PAGI\Client\Result\ExecResult](PAGI-Client-Result-ExecResult.md)
12
13
14
15
16
17 Properties
18 ----------
19
20
21 ### $status
22
23 private string $status
24
25 Cause
26
27
28
29 * Visibility: **private**
30
31
32 ### $cause
33
34 private string $cause
35
36 Cause
37
38
39
40 * Visibility: **private**
41
42
43 ### $result
44
45 private \PAGI\Client\Result\IResult $result
46
47 Our decorated result.
48
49
50
51 * Visibility: **private**
52
53
54 Methods
55 -------
56
57
58 ### getCause
59
60 string PAGI\Client\Result\AmdResult::getCause()
61
62 Returns the cause string.
63
64
65
66 * Visibility: **public**
67
68
69
70
71 ### getStatus
72
73 string PAGI\Client\Result\AmdResult::getStatus()
74
75 Returns the status string.
76
77
78
79 * Visibility: **public**
80
81
82
83
84 ### setCause
85
86 void PAGI\Client\Result\AmdResult::setCause(string $cause)
87
88 Sets the cause string
89
90
91
92 * Visibility: **public**
93
94
95 #### Arguments
96 * $cause **string**
97
98
99
100 ### setStatus
101
102 void PAGI\Client\Result\AmdResult::setStatus($status)
103
104 Sets the cause string
105
106
107
108 * Visibility: **public**
109
110
111 #### Arguments
112 * $status **mixed**
113
114
115
116 ### isStatus
117
118 boolean PAGI\Client\Result\AmdResult::isStatus(string $string)
119
120 True if the status equals the given string
121
122
123
124 * Visibility: **private**
125
126
127 #### Arguments
128 * $string **string**
129
130
131
132 ### isCause
133
134 boolean PAGI\Client\Result\AmdResult::isCause(string $string)
135
136 True if the cause equals the given string
137
138
139
140 * Visibility: **private**
141
142
143 #### Arguments
144 * $string **string**
145
146
147
148 ### isMachine
149
150 boolean PAGI\Client\Result\AmdResult::isMachine()
151
152 True if AMD detected an answering machine.
153
154
155
156 * Visibility: **public**
157
158
159
160
161 ### isHangup
162
163 boolean PAGI\Client\Result\AmdResult::isHangup()
164
165 True if AMD detected a hangup.
166
167
168
169 * Visibility: **public**
170
171
172
173
174 ### isHuman
175
176 boolean PAGI\Client\Result\AmdResult::isHuman()
177
178 True if AMD detected a human.
179
180
181
182 * Visibility: **public**
183
184
185
186
187 ### isNotSure
188
189 boolean PAGI\Client\Result\AmdResult::isNotSure()
190
191 True if AMD failed detecting an answering machine or human.
192
193
194
195 * Visibility: **public**
196
197
198
199
200 ### isCauseTooLong
201
202 boolean PAGI\Client\Result\AmdResult::isCauseTooLong()
203
204 True if AMD status is due to a timeout when detecting.
205
206
207
208 * Visibility: **public**
209
210
211
212
213 ### isCauseInitialSilence
214
215 boolean PAGI\Client\Result\AmdResult::isCauseInitialSilence()
216
217 True if AMD status is due to a silence duration.
218
219
220
221 * Visibility: **public**
222
223
224
225
226 ### isCauseHuman
227
228 boolean PAGI\Client\Result\AmdResult::isCauseHuman()
229
230 True if AMD status is due to a silence after a greeting.
231
232
233
234 * Visibility: **public**
235
236
237
238
239 ### isCauseGreeting
240
241 boolean PAGI\Client\Result\AmdResult::isCauseGreeting()
242
243 True if AMD status is due to a long greeting detected.
244
245
246
247 * Visibility: **public**
248
249
250
251
252 ### isCauseWordLength
253
254 boolean PAGI\Client\Result\AmdResult::isCauseWordLength()
255
256 True if AMD status is due to a maximum number of words reached.
257
258
259
260 * Visibility: **public**
261
262
263
264
265 ### __toString
266
267 string PAGI\Client\Result\ResultDecorator::__toString()
268
269 Standard procedure.
270
271
272
273 * Visibility: **public**
274 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
275
276
277
278
279 ### __construct
280
281 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
282
283 Constructor.
284
285
286
287 * Visibility: **public**
288 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
289
290
291 #### Arguments
292 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
293
294
295
296 ### getOriginalLine
297
298 string PAGI\Client\Result\IResult::getOriginalLine()
299
300 Returns original line.
301
302
303
304 * Visibility: **public**
305 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
306
307
308
309
310 ### getCode
311
312 integer PAGI\Client\Result\IResult::getCode()
313
314 Returns the integer value of the code returned by agi.
315
316
317
318 * Visibility: **public**
319 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
320
321
322
323
324 ### getResult
325
326 integer PAGI\Client\Result\IResult::getResult()
327
328 Returns result (result=xxx) from the result.
329
330
331
332 * Visibility: **public**
333 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
334
335
336
337
338 ### isResult
339
340 boolean PAGI\Client\Result\IResult::isResult(string $value)
341
342 Compares result to a given value.
343
344
345
346 * Visibility: **public**
347 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
348
349
350 #### Arguments
351 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
352
353
354
355 ### hasData
356
357 boolean PAGI\Client\Result\IResult::hasData()
358
359 Returns true if this command returned any data.
360
361
362
363 * Visibility: **public**
364 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
365
366
367
368
369 ### getData
370
371 string PAGI\Client\Result\IResult::getData()
372
373 Returns data, if any. False if none.
374
375
376
377 * Visibility: **public**
378 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
379
380
381
1 PAGI\Client\Result\DataReadResult
2 ===============
3
4 This decorated result adds the functionality to check for user input (more
5 than one digit).
6
7 PHP Version 5
8
9
10 * Class name: DataReadResult
11 * Namespace: PAGI\Client\Result
12 * Parent class: [PAGI\Client\Result\DigitReadResult](PAGI-Client-Result-DigitReadResult.md)
13
14
15
16
17
18 Properties
19 ----------
20
21
22 ### $digits
23
24 protected string $digits
25
26 Digits read (if any).
27
28
29
30 * Visibility: **protected**
31
32
33 ### $timeout
34
35 protected boolean $timeout
36
37 Timeout?
38
39
40
41 * Visibility: **protected**
42
43
44 ### $result
45
46 private \PAGI\Client\Result\IResult $result
47
48 Our decorated result.
49
50
51
52 * Visibility: **private**
53
54
55 Methods
56 -------
57
58
59 ### __construct
60
61 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
62
63 Constructor.
64
65
66
67 * Visibility: **public**
68 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
69
70
71 #### Arguments
72 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
73
74
75
76 ### isTimeout
77
78 boolean PAGI\Client\Result\IReadResult::isTimeout()
79
80 True if the operation completed and no input was received from the user.
81
82
83
84 * Visibility: **public**
85 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
86
87
88
89
90 ### getDigits
91
92 string PAGI\Client\Result\IReadResult::getDigits()
93
94 Returns digits read. False if none.
95
96
97
98 * Visibility: **public**
99 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
100
101
102
103
104 ### getDigitsCount
105
106 integer PAGI\Client\Result\IReadResult::getDigitsCount()
107
108 Returns the number of digits read.
109
110
111
112 * Visibility: **public**
113 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
114
115
116
117
118 ### getOriginalLine
119
120 string PAGI\Client\Result\IResult::getOriginalLine()
121
122 Returns original line.
123
124
125
126 * Visibility: **public**
127 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
128
129
130
131
132 ### getCode
133
134 integer PAGI\Client\Result\IResult::getCode()
135
136 Returns the integer value of the code returned by agi.
137
138
139
140 * Visibility: **public**
141 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
142
143
144
145
146 ### getResult
147
148 integer PAGI\Client\Result\IResult::getResult()
149
150 Returns result (result=xxx) from the result.
151
152
153
154 * Visibility: **public**
155 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
156
157
158
159
160 ### isResult
161
162 boolean PAGI\Client\Result\IResult::isResult(string $value)
163
164 Compares result to a given value.
165
166
167
168 * Visibility: **public**
169 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
170
171
172 #### Arguments
173 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
174
175
176
177 ### hasData
178
179 boolean PAGI\Client\Result\IResult::hasData()
180
181 Returns true if this command returned any data.
182
183
184
185 * Visibility: **public**
186 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
187
188
189
190
191 ### getData
192
193 string PAGI\Client\Result\IResult::getData()
194
195 Returns data, if any. False if none.
196
197
198
199 * Visibility: **public**
200 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
201
202
203
204
205 ### __toString
206
207 string PAGI\Client\Result\ResultDecorator::__toString()
208
209 Standard procedure.
210
211
212
213 * Visibility: **public**
214 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
215
216
217
1 PAGI\Client\Result\DialResult
2 ===============
3
4 This decorated result adds the functionality to check for a dial result.
5
6 PHP Version 5
7
8
9 * Class name: DialResult
10 * Namespace: PAGI\Client\Result
11 * Parent class: [PAGI\Client\Result\ExecResult](PAGI-Client-Result-ExecResult.md)
12
13
14
15
16
17 Properties
18 ----------
19
20
21 ### $dialedPeerNumber
22
23 private string $dialedPeerNumber
24
25 Dialed peer number.
26
27
28
29 * Visibility: **private**
30
31
32 ### $dialedPeerName
33
34 private string $dialedPeerName
35
36 Dialed peer name.
37
38
39
40 * Visibility: **private**
41
42
43 ### $dialedTime
44
45 private integer $dialedTime
46
47 Total call length in seconds.
48
49
50
51 * Visibility: **private**
52
53
54 ### $answeredTime
55
56 private integer $answeredTime
57
58 Total answered length in seconds.
59
60
61
62 * Visibility: **private**
63
64
65 ### $dialStatus
66
67 private string $dialStatus
68
69 Dial status.
70
71
72
73 * Visibility: **private**
74
75
76 ### $dynamicFeatures
77
78 private string $dynamicFeatures
79
80 Features available for the call.
81
82
83
84 * Visibility: **private**
85
86
87 ### $result
88
89 private \PAGI\Client\Result\IResult $result
90
91 Our decorated result.
92
93
94
95 * Visibility: **private**
96
97
98 Methods
99 -------
100
101
102 ### getPeerNumber
103
104 string PAGI\Client\Result\DialResult::getPeerNumber()
105
106 Returns Peer number.
107
108
109
110 * Visibility: **public**
111
112
113
114
115 ### setPeerNumber
116
117 void PAGI\Client\Result\DialResult::setPeerNumber(string $number)
118
119 Set peer number.
120
121
122
123 * Visibility: **public**
124
125
126 #### Arguments
127 * $number **string** - &lt;p&gt;Peer number.&lt;/p&gt;
128
129
130
131 ### getPeerName
132
133 string PAGI\Client\Result\DialResult::getPeerName()
134
135 Returns Peer name.
136
137
138
139 * Visibility: **public**
140
141
142
143
144 ### setPeerName
145
146 void PAGI\Client\Result\DialResult::setPeerName(string $name)
147
148 Set peer name.
149
150
151
152 * Visibility: **public**
153
154
155 #### Arguments
156 * $name **string** - &lt;p&gt;Peer name.&lt;/p&gt;
157
158
159
160 ### getDialedTime
161
162 integer PAGI\Client\Result\DialResult::getDialedTime()
163
164 Returns total time for the call in seconds.
165
166
167
168 * Visibility: **public**
169
170
171
172
173 ### setDialedTime
174
175 void PAGI\Client\Result\DialResult::setDialedTime(integer $time)
176
177 Set dialed time.
178
179
180
181 * Visibility: **public**
182
183
184 #### Arguments
185 * $time **integer** - &lt;p&gt;Dialed time.&lt;/p&gt;
186
187
188
189 ### getAnsweredTime
190
191 integer PAGI\Client\Result\DialResult::getAnsweredTime()
192
193 Returns answered time.
194
195
196
197 * Visibility: **public**
198
199
200
201
202 ### setAnsweredTime
203
204 void PAGI\Client\Result\DialResult::setAnsweredTime(integer $time)
205
206 Set answered time.
207
208
209
210 * Visibility: **public**
211
212
213 #### Arguments
214 * $time **integer** - &lt;p&gt;Answered time.&lt;/p&gt;
215
216
217
218 ### getDialStatus
219
220 string PAGI\Client\Result\DialResult::getDialStatus()
221
222 Returns dial status.
223
224
225
226 * Visibility: **public**
227
228
229
230
231 ### isBusy
232
233 boolean PAGI\Client\Result\DialResult::isBusy()
234
235 Returns true if the result was BUSY.
236
237
238
239 * Visibility: **public**
240
241
242
243
244 ### isCongestion
245
246 boolean PAGI\Client\Result\DialResult::isCongestion()
247
248 Returns true if the result was CONGESTION.
249
250
251
252 * Visibility: **public**
253
254
255
256
257 ### isCancel
258
259 boolean PAGI\Client\Result\DialResult::isCancel()
260
261 Returns true if the result was CANCEL.
262
263
264
265 * Visibility: **public**
266
267
268
269
270 ### isAnswer
271
272 boolean PAGI\Client\Result\DialResult::isAnswer()
273
274 Returns true if the result was ANSWER.
275
276
277
278 * Visibility: **public**
279
280
281
282
283 ### isNoAnswer
284
285 boolean PAGI\Client\Result\DialResult::isNoAnswer()
286
287 Returns true if the result was NOANSWER.
288
289
290
291 * Visibility: **public**
292
293
294
295
296 ### isChanUnavailable
297
298 boolean PAGI\Client\Result\DialResult::isChanUnavailable()
299
300 Returns true if the result was CHANUNAVAIL.
301
302
303
304 * Visibility: **public**
305
306
307
308
309 ### setDialStatus
310
311 void PAGI\Client\Result\DialResult::setDialStatus(string $status)
312
313 Set dial status.
314
315
316
317 * Visibility: **public**
318
319
320 #### Arguments
321 * $status **string** - &lt;p&gt;Dial status.&lt;/p&gt;
322
323
324
325 ### getDynamicFeatures
326
327 string PAGI\Client\Result\DialResult::getDynamicFeatures()
328
329 Returns features available for the call.
330
331
332
333 * Visibility: **public**
334
335
336
337
338 ### setDynamicFeatures
339
340 void PAGI\Client\Result\DialResult::setDynamicFeatures(string $features)
341
342 Set features.
343
344
345
346 * Visibility: **public**
347
348
349 #### Arguments
350 * $features **string** - &lt;p&gt;Features.&lt;/p&gt;
351
352
353
354 ### __toString
355
356 string PAGI\Client\Result\ResultDecorator::__toString()
357
358 Standard procedure.
359
360
361
362 * Visibility: **public**
363 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
364
365
366
367
368 ### __construct
369
370 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
371
372 Constructor.
373
374
375
376 * Visibility: **public**
377 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
378
379
380 #### Arguments
381 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
382
383
384
385 ### getOriginalLine
386
387 string PAGI\Client\Result\IResult::getOriginalLine()
388
389 Returns original line.
390
391
392
393 * Visibility: **public**
394 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
395
396
397
398
399 ### getCode
400
401 integer PAGI\Client\Result\IResult::getCode()
402
403 Returns the integer value of the code returned by agi.
404
405
406
407 * Visibility: **public**
408 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
409
410
411
412
413 ### getResult
414
415 integer PAGI\Client\Result\IResult::getResult()
416
417 Returns result (result=xxx) from the result.
418
419
420
421 * Visibility: **public**
422 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
423
424
425
426
427 ### isResult
428
429 boolean PAGI\Client\Result\IResult::isResult(string $value)
430
431 Compares result to a given value.
432
433
434
435 * Visibility: **public**
436 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
437
438
439 #### Arguments
440 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
441
442
443
444 ### hasData
445
446 boolean PAGI\Client\Result\IResult::hasData()
447
448 Returns true if this command returned any data.
449
450
451
452 * Visibility: **public**
453 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
454
455
456
457
458 ### getData
459
460 string PAGI\Client\Result\IResult::getData()
461
462 Returns data, if any. False if none.
463
464
465
466 * Visibility: **public**
467 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
468
469
470
1 PAGI\Client\Result\DigitReadResult
2 ===============
3
4 This decorated result adds the functionality to check for user input. We
5 need a distinction between a single digit read (this class) and a data read
6 (DataReadResult) because asterisk sends the ascii number for the character
7 read (the first case) and the literal string in the latter.
8
9 PHP Version 5
10
11
12 * Class name: DigitReadResult
13 * Namespace: PAGI\Client\Result
14 * Parent class: [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
15 * This class implements: [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
16
17
18
19
20 Properties
21 ----------
22
23
24 ### $digits
25
26 protected string $digits
27
28 Digits read (if any).
29
30
31
32 * Visibility: **protected**
33
34
35 ### $timeout
36
37 protected boolean $timeout
38
39 Timeout?
40
41
42
43 * Visibility: **protected**
44
45
46 ### $result
47
48 private \PAGI\Client\Result\IResult $result
49
50 Our decorated result.
51
52
53
54 * Visibility: **private**
55
56
57 Methods
58 -------
59
60
61 ### isTimeout
62
63 boolean PAGI\Client\Result\IReadResult::isTimeout()
64
65 True if the operation completed and no input was received from the user.
66
67
68
69 * Visibility: **public**
70 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
71
72
73
74
75 ### getDigits
76
77 string PAGI\Client\Result\IReadResult::getDigits()
78
79 Returns digits read. False if none.
80
81
82
83 * Visibility: **public**
84 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
85
86
87
88
89 ### getDigitsCount
90
91 integer PAGI\Client\Result\IReadResult::getDigitsCount()
92
93 Returns the number of digits read.
94
95
96
97 * Visibility: **public**
98 * This method is defined by [PAGI\Client\Result\IReadResult](PAGI-Client-Result-IReadResult.md)
99
100
101
102
103 ### __construct
104
105 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
106
107 Constructor.
108
109
110
111 * Visibility: **public**
112 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
113
114
115 #### Arguments
116 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
117
118
119
120 ### getOriginalLine
121
122 string PAGI\Client\Result\IResult::getOriginalLine()
123
124 Returns original line.
125
126
127
128 * Visibility: **public**
129 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
130
131
132
133
134 ### getCode
135
136 integer PAGI\Client\Result\IResult::getCode()
137
138 Returns the integer value of the code returned by agi.
139
140
141
142 * Visibility: **public**
143 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
144
145
146
147
148 ### getResult
149
150 integer PAGI\Client\Result\IResult::getResult()
151
152 Returns result (result=xxx) from the result.
153
154
155
156 * Visibility: **public**
157 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
158
159
160
161
162 ### isResult
163
164 boolean PAGI\Client\Result\IResult::isResult(string $value)
165
166 Compares result to a given value.
167
168
169
170 * Visibility: **public**
171 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
172
173
174 #### Arguments
175 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
176
177
178
179 ### hasData
180
181 boolean PAGI\Client\Result\IResult::hasData()
182
183 Returns true if this command returned any data.
184
185
186
187 * Visibility: **public**
188 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
189
190
191
192
193 ### getData
194
195 string PAGI\Client\Result\IResult::getData()
196
197 Returns data, if any. False if none.
198
199
200
201 * Visibility: **public**
202 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
203
204
205
206
207 ### __toString
208
209 string PAGI\Client\Result\ResultDecorator::__toString()
210
211 Standard procedure.
212
213
214
215 * Visibility: **public**
216 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
217
218
219
1 PAGI\Client\Result\ExecResult
2 ===============
3
4 This decorated result adds the functionality to check for an exec result.
5
6 PHP Version 5
7
8
9 * Class name: ExecResult
10 * Namespace: PAGI\Client\Result
11 * Parent class: [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
12
13
14
15
16
17 Properties
18 ----------
19
20
21 ### $result
22
23 private \PAGI\Client\Result\IResult $result
24
25 Our decorated result.
26
27
28
29 * Visibility: **private**
30
31
32 Methods
33 -------
34
35
36 ### __construct
37
38 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
39
40 Constructor.
41
42
43
44 * Visibility: **public**
45 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
46
47
48 #### Arguments
49 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
50
51
52
53 ### getOriginalLine
54
55 string PAGI\Client\Result\IResult::getOriginalLine()
56
57 Returns original line.
58
59
60
61 * Visibility: **public**
62 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
63
64
65
66
67 ### getCode
68
69 integer PAGI\Client\Result\IResult::getCode()
70
71 Returns the integer value of the code returned by agi.
72
73
74
75 * Visibility: **public**
76 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
77
78
79
80
81 ### getResult
82
83 integer PAGI\Client\Result\IResult::getResult()
84
85 Returns result (result=xxx) from the result.
86
87
88
89 * Visibility: **public**
90 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
91
92
93
94
95 ### isResult
96
97 boolean PAGI\Client\Result\IResult::isResult(string $value)
98
99 Compares result to a given value.
100
101
102
103 * Visibility: **public**
104 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
105
106
107 #### Arguments
108 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
109
110
111
112 ### hasData
113
114 boolean PAGI\Client\Result\IResult::hasData()
115
116 Returns true if this command returned any data.
117
118
119
120 * Visibility: **public**
121 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
122
123
124
125
126 ### getData
127
128 string PAGI\Client\Result\IResult::getData()
129
130 Returns data, if any. False if none.
131
132
133
134 * Visibility: **public**
135 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
136
137
138
139
140 ### __toString
141
142 string PAGI\Client\Result\ResultDecorator::__toString()
143
144 Standard procedure.
145
146
147
148 * Visibility: **public**
149 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
150
151
152
1 PAGI\Client\Result\FaxResult
2 ===============
3
4 This decorated result adds the functionality to check for a fax result.
5
6 PHP Version 5
7
8
9 * Class name: FaxResult
10 * Namespace: PAGI\Client\Result
11 * Parent class: [PAGI\Client\Result\ExecResult](PAGI-Client-Result-ExecResult.md)
12
13
14
15
16
17 Properties
18 ----------
19
20
21 ### $localId
22
23 private string $localId
24
25 Local station ID.
26
27
28
29 * Visibility: **private**
30
31
32 ### $localHeader
33
34 private string $localHeader
35
36 Local header.
37
38
39
40 * Visibility: **private**
41
42
43 ### $remoteId
44
45 private string $remoteId
46
47 Remote station ID.
48
49
50
51 * Visibility: **private**
52
53
54 ### $result
55
56 private \PAGI\Client\Result\IResult $result
57
58 Our decorated result.
59
60
61
62 * Visibility: **private**
63
64
65 ### $error
66
67 private string $error
68
69 Error detail (if $result === false)
70
71
72
73 * Visibility: **private**
74
75
76 ### $bitrate
77
78 private integer $bitrate
79
80 Bitrate for the operation.
81
82
83
84 * Visibility: **private**
85
86
87 ### $pages
88
89 private integer $pages
90
91 Total pages for the operation.
92
93
94
95 * Visibility: **private**
96
97
98 ### $resolution
99
100 private string $resolution
101
102 Resolution for the operation.
103
104
105
106 * Visibility: **private**
107
108
109 Methods
110 -------
111
112
113 ### getLocalStationId
114
115 string PAGI\Client\Result\FaxResult::getLocalStationId()
116
117 Returns local station id.
118
119
120
121 * Visibility: **public**
122
123
124
125
126 ### setLocalStationId
127
128 void PAGI\Client\Result\FaxResult::setLocalStationId(string $value)
129
130 Sets local station id.
131
132
133
134 * Visibility: **public**
135
136
137 #### Arguments
138 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
139
140
141
142 ### getLocalHeaderInfo
143
144 string PAGI\Client\Result\FaxResult::getLocalHeaderInfo()
145
146 Returns local header.
147
148
149
150 * Visibility: **public**
151
152
153
154
155 ### setLocalHeaderInfo
156
157 void PAGI\Client\Result\FaxResult::setLocalHeaderInfo(string $value)
158
159 Sets local header.
160
161
162
163 * Visibility: **public**
164
165
166 #### Arguments
167 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
168
169
170
171 ### isSuccess
172
173 boolean PAGI\Client\Result\FaxResult::isSuccess()
174
175 True if the operation was successfull.
176
177
178
179 * Visibility: **public**
180
181
182
183
184 ### setResult
185
186 void PAGI\Client\Result\FaxResult::setResult(string $value)
187
188 Sets operation result (if failed).
189
190
191
192 * Visibility: **public**
193
194
195 #### Arguments
196 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
197
198
199
200 ### getError
201
202 string PAGI\Client\Result\FaxResult::getError()
203
204 Returns error description (if failed).
205
206
207
208 * Visibility: **public**
209
210
211
212
213 ### setError
214
215 void PAGI\Client\Result\FaxResult::setError(string $value)
216
217 Sets error detail.
218
219
220
221 * Visibility: **public**
222
223
224 #### Arguments
225 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
226
227
228
229 ### getRemoteStationId
230
231 string PAGI\Client\Result\FaxResult::getRemoteStationId()
232
233 Returns remote station id.
234
235
236
237 * Visibility: **public**
238
239
240
241
242 ### setRemoteStationId
243
244 void PAGI\Client\Result\FaxResult::setRemoteStationId(string $value)
245
246 Sets remote station id.
247
248
249
250 * Visibility: **public**
251
252
253 #### Arguments
254 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
255
256
257
258 ### getPages
259
260 integer PAGI\Client\Result\FaxResult::getPages()
261
262 Returns number of pages.
263
264
265
266 * Visibility: **public**
267
268
269
270
271 ### setPages
272
273 void PAGI\Client\Result\FaxResult::setPages(integer $value)
274
275 Sets number of pages.
276
277
278
279 * Visibility: **public**
280
281
282 #### Arguments
283 * $value **integer** - &lt;p&gt;Value to set.&lt;/p&gt;
284
285
286
287 ### getBitrate
288
289 integer PAGI\Client\Result\FaxResult::getBitrate()
290
291 Returns bitrate.
292
293
294
295 * Visibility: **public**
296
297
298
299
300 ### setBitrate
301
302 void PAGI\Client\Result\FaxResult::setBitrate(integer $value)
303
304 Sets bitrate.
305
306
307
308 * Visibility: **public**
309
310
311 #### Arguments
312 * $value **integer** - &lt;p&gt;Value to set.&lt;/p&gt;
313
314
315
316 ### getResolution
317
318 string PAGI\Client\Result\FaxResult::getResolution()
319
320 Returns resolution for the operation.
321
322
323
324 * Visibility: **public**
325
326
327
328
329 ### setResolution
330
331 void PAGI\Client\Result\FaxResult::setResolution(string $value)
332
333 Sets resolution.
334
335
336
337 * Visibility: **public**
338
339
340 #### Arguments
341 * $value **string** - &lt;p&gt;Value to set.&lt;/p&gt;
342
343
344
345 ### __toString
346
347 string PAGI\Client\Result\ResultDecorator::__toString()
348
349 Standard procedure.
350
351
352
353 * Visibility: **public**
354 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
355
356
357
358
359 ### __construct
360
361 void PAGI\Client\Result\ResultDecorator::__construct(\PAGI\Client\Result\IResult $result)
362
363 Constructor.
364
365
366
367 * Visibility: **public**
368 * This method is defined by [PAGI\Client\Result\ResultDecorator](PAGI-Client-Result-ResultDecorator.md)
369
370
371 #### Arguments
372 * $result **[PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)** - &lt;p&gt;Result to decorate.&lt;/p&gt;
373
374
375
376 ### getOriginalLine
377
378 string PAGI\Client\Result\IResult::getOriginalLine()
379
380 Returns original line.
381
382
383
384 * Visibility: **public**
385 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
386
387
388
389
390 ### getCode
391
392 integer PAGI\Client\Result\IResult::getCode()
393
394 Returns the integer value of the code returned by agi.
395
396
397
398 * Visibility: **public**
399 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
400
401
402
403
404 ### getResult
405
406 integer PAGI\Client\Result\IResult::getResult()
407
408 Returns result (result=xxx) from the result.
409
410
411
412 * Visibility: **public**
413 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
414
415
416
417
418 ### isResult
419
420 boolean PAGI\Client\Result\IResult::isResult(string $value)
421
422 Compares result to a given value.
423
424
425
426 * Visibility: **public**
427 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
428
429
430 #### Arguments
431 * $value **string** - &lt;p&gt;Value to match against.&lt;/p&gt;
432
433
434
435 ### hasData
436
437 boolean PAGI\Client\Result\IResult::hasData()
438
439 Returns true if this command returned any data.
440
441
442
443 * Visibility: **public**
444 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
445
446
447
448
449 ### getData
450
451 string PAGI\Client\Result\IResult::getData()
452
453 Returns data, if any. False if none.
454
455
456
457 * Visibility: **public**
458 * This method is defined by [PAGI\Client\Result\IResult](PAGI-Client-Result-IResult.md)
459
460
461
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!