CacheDecoratorInterface::writeCache

public CacheDecoratorInterface::writeCache() Write the cache. File core/lib/Drupal/Core/CacheDecorator/CacheDecoratorInterface.php, line 18 Class CacheDecoratorInterface Defines an interface for cache decorator implementations. Namespace Drupal\Core\CacheDecorator Code public function writeCache();

CacheDecoratorInterface::setCacheKey

public CacheDecoratorInterface::setCacheKey($key) Specify the key to use when writing the cache. File core/lib/Drupal/Core/CacheDecorator/CacheDecoratorInterface.php, line 13 Class CacheDecoratorInterface Defines an interface for cache decorator implementations. Namespace Drupal\Core\CacheDecorator Code public function setCacheKey($key);

CacheDecoratorInterface

Defines an interface for cache decorator implementations. Hierarchy interface \Drupal\Core\CacheDecorator\CacheDecoratorInterface File core/lib/Drupal/Core/CacheDecorator/CacheDecoratorInterface.php, line 8 Namespace Drupal\Core\CacheDecorator Members Name Modifiers Type Description CacheDecoratorInterface::setCacheKey public function Specify the key to use when writing the cache. CacheDecoratorInterface::writeCache public function Write the cache.

CacheContextsPass::process

public CacheContextsPass::process(ContainerBuilder $container) Implements CompilerPassInterface::process(). Collects the cache contexts into the cache_contexts parameter. Overrides CompilerPassInterface::process File core/lib/Drupal/Core/Cache/Context/CacheContextsPass.php, line 18 Class CacheContextsPass Adds cache_contexts parameter to the container. Namespace Drupal\Core\Cache\Context Code public function process(ContainerBuilder $container) { $cache_contexts = []; foreach (arra

CacheContextsPass

Adds cache_contexts parameter to the container. Hierarchy class \Drupal\Core\Cache\Context\CacheContextsPass implements CompilerPassInterface File core/lib/Drupal/Core/Cache/Context/CacheContextsPass.php, line 11 Namespace Drupal\Core\Cache\Context Members Name Modifiers Type Description CacheContextsPass::process public function Implements CompilerPassInterface::process(). Overrides CompilerPassInterface::process

CacheContextsManager::__construct

public CacheContextsManager::__construct(ContainerInterface $container, array $contexts) Constructs a CacheContextsManager object. Parameters \Symfony\Component\DependencyInjection\ContainerInterface $container: The current service container. string[] $contexts: An array of the available cache context IDs. File core/lib/Drupal/Core/Cache/Context/CacheContextsManager.php, line 47 Class CacheContextsManager Converts cache context tokens into cache keys. Namespace Drupal\Core\Cache\Contex

CacheContextsManager::validateTokens

public CacheContextsManager::validateTokens(array $context_tokens = []) Validates an array of cache context tokens. Can be called before using cache contexts in operations, to check validity. Parameters string[] $context_tokens: An array of cache context tokens. Throws \LogicException See also \Drupal\Core\Cache\Context\CacheContextsManager::parseTokens() File core/lib/Drupal/Core/Cache/Context/CacheContextsManager.php, line 258 Class CacheContextsManager Converts cache context tokens i

CacheContextsManager::parseTokens

public static CacheContextsManager::parseTokens(array $context_tokens) Parses cache context tokens into context IDs and optional parameters. Parameters string[] $context_tokens: An array of cache context tokens. Return value array An array with the parsed results, with each result being an array containing: The cache context ID. The associated parameter (for a calculated cache context), or NULL if there is no parameter. File core/lib/Drupal/Core/Cache/Context/CacheContextsManager.php, line

CacheContextsManager::optimizeTokens

public CacheContextsManager::optimizeTokens(array $context_tokens) Optimizes cache context tokens (the minimal representative subset). A minimal representative subset means that any cache context token in the given set of cache context tokens that is a property of another cache context cache context token in the set, is removed. Hence a minimal representative subset is the most compact representation possible of a set of cache context tokens, that still captures the entire universe of variation

CacheContextsManager::getService

protected CacheContextsManager::getService($context_id) Retrieves a cache context service from the container. Parameters string $context_id: The context ID, which together with the service ID prefix allows the corresponding cache context service to be retrieved. Return value \Drupal\Core\Cache\Context\CacheContextInterface The requested cache context service. File core/lib/Drupal/Core/Cache/Context/CacheContextsManager.php, line 216 Class CacheContextsManager Converts cache context token