You are here

protected function MiconIconManager::getCachedDefinitions in Micon 8

Same name and namespace in other branches
  1. 2.x src/MiconIconManager.php \Drupal\micon\MiconIconManager::getCachedDefinitions()

Returns the cached Micon icons.

Return value

array|null On success this will return an array of Micon icons. On failure this should return NULL, indicating to other methods that this has not yet been defined. Success with no values should return as an empty array and would actually be returned by the getIcons() method.

1 call to MiconIconManager::getCachedDefinitions()
MiconIconManager::getIcons in src/MiconIconManager.php
Get all available icons.

File

src/MiconIconManager.php, line 137

Class

MiconIconManager
Class MiconIconManager.

Namespace

Drupal\micon

Code

protected function getCachedDefinitions() {
  if (!isset($this->icons) && ($cache = $this
    ->cacheGet($this->cacheKey))) {
    $this->icons = $cache->data;
  }
  return $this->icons;
}