function GenericEvent::getArgument
Get argument by key.
Throws
\InvalidArgumentException if key is not found
1 call to GenericEvent::getArgument()
- GenericEvent::offsetGet in vendor/
symfony/ event-dispatcher/ GenericEvent.php - ArrayAccess for argument getter.
File
-
vendor/
symfony/ event-dispatcher/ GenericEvent.php, line 53
Class
- GenericEvent
- Event encapsulation class.
Namespace
Symfony\Component\EventDispatcherCode
public function getArgument(string $key) : mixed {
if ($this->hasArgument($key)) {
return $this->arguments[$key];
}
throw new \InvalidArgumentException(\sprintf('Argument "%s" not found.', $key));
}