public function __construct(Client $client, $type = null, $name = null, $region = null, $urlType = null) { parent::__construct($client, $type, $name, $region, $urlType); if (strpos($this->getUrl()->getPath(), '/v1') !== false) { throw new Exceptions\UnsupportedVersionError(sprintf(Lang::translate('Sorry; API version /v1 is not supported [%s]'), $this->getUrl())); } $this->loadNamespaces(); }
public function __construct(Client $client, $type = null, $name = null, $region = null, $urlType = null) { parent::__construct($client, $type, $name, $region, $urlType); // @see https://github.com/rackspace/php-opencloud/issues/353 if (strpos($this->getUrl()->getPath(), '/v1.0/') !== false) { throw new Exceptions\UnsupportedVersionError(sprintf('Sorry; API version /v1.0 is not supported [%s]', $this->getUrl())); } $this->loadNamespaces(); }
/** * Returns a list of flavors * * just call the parent FlavorList() method, but pass FALSE * because the /flavors/detail resource is not supported * * @api * @return \OpenCloud\Compute\FlavorList */ public function flavorList($details = false, array $filter = array()) { return parent::flavorList(false); }