/** * @param null $category * @param null $example * @internal param null $activeCategory * @internal param null $activeExample */ function __construct(PageInfo $pageInfo) { $this->activeCategory = $pageInfo->getCategory(); //$category; $this->activeExample = $pageInfo->getExample(); //$example; }
/** * @param $category * @param $example */ function __construct(PageInfo $pageInfo) { $this->category = $pageInfo->getCategory(); $this->currentExample = $pageInfo->getExample(); $this->exampleList = $this->getCategoryList($this->category); $this->pageInfo = $pageInfo; }
public function __construct(ImagickTaskQueue $taskQueue, PageInfo $pageInfo) { $activeCategory = $pageInfo->getCategory(); $activeExample = $pageInfo->getExample(); $this->taskQueue = $taskQueue; $this->activeCategory = $activeCategory; $this->activeExample = $activeExample; }
function __construct(PageInfo $pageInfo, ImagickTaskQueue $taskQueue) { $activeCategory = $pageInfo->getCategory(); $activeExample = $pageInfo->getExample(); $this->imageBaseURL = getImageURL($activeCategory, $activeExample); $this->customImageBaseURL = getCustomImageURL($activeCategory, $activeExample); $this->imageStatusBaseURL = getImageStatusURL($activeCategory, $activeExample); $this->taskQueue = $taskQueue; }
public function getImageCacheFilename(PageInfo $pageInfo, $params) { $category = $pageInfo->getCategory(); $example = $pageInfo->getExample(); $filename = $this->getPath() . "/" . $category . '/' . $example . '/' . $example; if (!empty($params)) { $filename .= '_' . md5(json_encode($params)); } return $filename; }
public function __construct(PageInfo $pageInfo, ImagickTaskQueue $taskQueue) { $activeCategory = $pageInfo->getCategory(); $activeExample = $pageInfo->getExample(); $this->imageBaseURL = \ImagickDemo\Route::getImageURL($activeCategory, $activeExample); $this->orignalImageBaseURL = \ImagickDemo\Route::getOriginalImageURL($activeCategory, $activeExample); $this->customImageBaseURL = \ImagickDemo\Route::getCustomImageURL($activeCategory, $activeExample); $this->imageStatusBaseURL = \ImagickDemo\Route::getImageStatusURL($activeCategory, $activeExample); $this->taskQueue = $taskQueue; }
public static function getDIInfo(PageInfo $pageInfo) { $category = $pageInfo->getCategory(); $example = $pageInfo->getExample(); if ($category == null || $example == null) { return ['ImagickDemo\\Control\\NullControl', []]; } $exampleDefinition = self::getExampleDefinition($category, $example); $controlClass = $exampleDefinition[1]; $params = []; if (array_key_exists('defaultParams', $exampleDefinition) == true) { foreach ($exampleDefinition['defaultParams'] as $name => $value) { $defaultName = 'default' . ucfirst($name); $params[$defaultName] = $value; } } return [$controlClass, $params]; }
/** * */ public function getKey() { $key = hash("sha256", json_encode($this->params)); return sprintf("%s_%s_%s", $this->pageInfo->getCategory(), $this->pageInfo->getExample(), $key); }
function __construct(\ImagickDemo\Helper\PageInfo $pageInfo) { $category = $pageInfo->getCategory(); $example = $pageInfo->getExample(); $this->category = strtolower($category); $this->example = strtolower($example); }
function __construct(PageInfo $pageInfo) { $category = $pageInfo->getCategory(); $example = $pageInfo->getExample(); $this->categoryCase = $category; $this->exampleCase = $example; $this->category = strtolower($category); $this->example = strtolower($example); }