public function buildConfiguration()
 {
     $config = Configuration::fromEnvironmentVariable(CloudinaryEnvironmentVariable::fromString($this->getEnvironmentVariable()));
     if ($this->getCdnSubdomainFlag()) {
         $config->enableCdnSubdomain();
     }
     $config->getDefaultTransformation()->withGravity(Gravity::fromString($this->getDefaultGravity()))->withFetchFormat(FetchFormat::fromString($this->getFetchFormat()))->withQuality(Quality::fromString($this->getImageQuality()))->withDpr(Dpr::fromString($this->getImageDpr()));
     return $config;
 }
예제 #2
0
 private function _getConfiguration($environmentVariable)
 {
     return Configuration::fromEnvironmentVariable(CloudinaryEnvironmentVariable::fromString($environmentVariable));
 }