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

Breadcrumb

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

function Registry::getRuntime

Returns the incomplete, runtime theme registry.

Return value

\Drupal\Core\Utility\ThemeRegistry A shared instance of the ThemeRegistry class, provides an ArrayObject that allows it to be accessed with array syntax and isset(), and is more lightweight than the full registry.

File

core/lib/Drupal/Core/Theme/Registry.php, line 311

Class

Registry
Defines the theme registry service.

Namespace

Drupal\Core\Theme

Code

public function getRuntime() {
    $this->init($this->themeName);
    if (!isset($this->runtimeRegistry[$this->theme
        ->getName()])) {
        $this->runtimeRegistry[$this->theme
            ->getName()] = new ThemeRegistry('theme_registry:runtime:' . $this->theme
            ->getName(), $this->runtimeCache ?: $this->cache, $this->lock, [], $this->moduleHandler
            ->isLoaded());
    }
    return $this->runtimeRegistry[$this->theme
        ->getName()];
}

API Navigation

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