Sets an option.
\InvalidArgumentException
public function setOption(string $key, mixed $value) : void { if (!\array_key_exists($key, $this->options)) { throw new \InvalidArgumentException(\sprintf('The Router does not support the "%s" option.', $key)); } $this->options[$key] = $value; }