abstract class AbstractThemeSuggestionsEvent in Hook Event Dispatcher 8.2
Same name and namespace in other branches
- 3.x modules/core_event_dispatcher/src/Event/Theme/AbstractThemeSuggestionsEvent.php \Drupal\core_event_dispatcher\Event\Theme\AbstractThemeSuggestionsEvent
Class AbstractThemeSuggestionsEvent.
Hierarchy
- class \Drupal\core_event_dispatcher\Event\Theme\AbstractThemeSuggestionsEvent extends \Symfony\Component\EventDispatcher\Event implements EventInterface
Expanded class hierarchy of AbstractThemeSuggestionsEvent
File
- modules/
core_event_dispatcher/ src/ Event/ Theme/ AbstractThemeSuggestionsEvent.php, line 11
Namespace
Drupal\core_event_dispatcher\Event\ThemeView source
abstract class AbstractThemeSuggestionsEvent extends Event implements EventInterface {
/**
* Array of suggestions.
*
* @var array
*/
private $suggestions;
/**
* Variables.
*
* @var array
*/
private $variables;
/**
* Hook name.
*
* @var string
*/
private $hook;
/**
* AbstractThemeSuggestionsEvent constructor.
*
* @param array $suggestions
* Suggestions.
* @param array $variables
* Variables.
* @param string $hook
* Hook name.
*/
public function __construct(array &$suggestions, array $variables, string $hook) {
$this->suggestions =& $suggestions;
$this->variables = $variables;
$this->hook = $hook;
}
/**
* Get suggestions.
*
* @return array
* Array of suggestions.
*/
public function &getSuggestions() : array {
return $this->suggestions;
}
/**
* Get variables.
*
* @return array
* Array of variables.
*/
public function getVariables() : array {
return $this->variables;
}
/**
* Get hook.
*
* @return string
* Name of the hook.
*/
public function getHook() : string {
return $this->hook;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AbstractThemeSuggestionsEvent:: |
private | property | Hook name. | |
AbstractThemeSuggestionsEvent:: |
private | property | Array of suggestions. | |
AbstractThemeSuggestionsEvent:: |
private | property | Variables. | |
AbstractThemeSuggestionsEvent:: |
public | function | Get hook. | |
AbstractThemeSuggestionsEvent:: |
public | function | Get suggestions. | |
AbstractThemeSuggestionsEvent:: |
public | function | Get variables. | |
AbstractThemeSuggestionsEvent:: |
public | function | AbstractThemeSuggestionsEvent constructor. | |
EventInterface:: |
public | function | Get the dispatcher type. | 75 |