protected function CacheContexts::getService in Render cache 7.2
Retrieves a service from the container.
Parameters
string $service: The ID of the service to retrieve.
Return value
mixed The specified service.
File
- lib/
Drupal/ Core/ Cache/ CacheContexts.php, line 123 - Contains \Drupal\Core\Cache\CacheContexts.
Class
- CacheContexts
- Defines the CacheContexts service.
Namespace
Drupal\Core\CacheCode
protected function getService($service) {
return $this->container
->get($service);
}