public function get(string
$key, mixed
$default = null
): string|int|float|bool|null
{ if (null !==
$default && !\
is_scalar($default) && !
$default instanceof \Stringable
) { throw new \
InvalidArgumentException(sprintf('Expected a scalar value as a 2nd argument to "%s()", "%s" given.', __METHOD__,
get_debug_type($default)));
} $value = parent::
get($key,
$this);
if (null !==
$value &&
$this !==
$value && !\
is_scalar($value) && !
$value instanceof \Stringable
) { throw new BadRequestException(sprintf('Input value "%s" contains a non-scalar value.',
$key));
} return $this ===
$value ?
$default :
$value;
} /**
* Replaces the current input values by a new set.
*/
public function replace(array
$inputs =
[]): void
{ $this->parameters =
[];