Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ArrayLoader.php

function ArrayLoader::getCacheKey

Overrides LoaderInterface::getCacheKey

File

vendor/twig/twig/src/Loader/ArrayLoader.php, line 58

Class

ArrayLoader
Loads a template from an array.

Namespace

Twig\Loader

Code

public function getCacheKey(string $name) : string {
    if (!isset($this->templates[$name])) {
        throw new LoaderError(\sprintf('Template "%s" is not defined.', $name));
    }
    return $name . ':' . $this->templates[$name];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal