You are here

public function PageEventVariables::getByReference in Hook Event Dispatcher 8

Get a variable with a given name by reference.

Parameters

string $name: Variable name.

Return value

mixed Reference for the variable.

Overrides AbstractEventVariables::getByReference

File

src/Event/Preprocess/Variables/PageEventVariables.php, line 94

Class

PageEventVariables
Class PageEventVariables.

Namespace

Drupal\hook_event_dispatcher\Event\Preprocess\Variables

Code

public function &getByReference($name) {
  return $this->variables['page'][$name];
}