1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44:
<?php
namespace Angelfon\SDK\Rest;
use Angelfon\SDK\Domain;
use Angelfon\SDK\Rest\Client;
use Angelfon\SDK\Rest\Api\V099;
class Api extends Domain
{
protected $_v099;
function __construct(Client $client)
{
parent::__construct($client);
$this->baseUrl = 'https://api.angelfon.com';
}
function getV099()
{
if (!$this->_v099) $this->_v099 = new V099($this);
return $this->_v099;
}
public function __get($name) {
$method = 'get' . ucfirst($name);
if (method_exists($this, $method)) {
return $this->$method();
}
throw new AngelfonException('Unknown version ' . $name);
}
}