public function Router::setOption in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/routing/Router.php \Symfony\Component\Routing\Router::setOption()
Sets an option.
Parameters
string $key The key:
mixed $value The value:
Throws
\InvalidArgumentException
File
- vendor/
symfony/ routing/ Router.php, line 157
Class
- Router
- The Router class is an example of the integration of all pieces of the routing system for easier use.
Namespace
Symfony\Component\RoutingCode
public function setOption($key, $value) {
if (!array_key_exists($key, $this->options)) {
throw new \InvalidArgumentException(sprintf('The Router does not support the "%s" option.', $key));
}
$this->options[$key] = $value;
}