(PHP 5 >= 5.0.3, PHP 7, PHP 8)
ReflectionParameter::isOptional — Checks if optional
Checks if the parameter is optional.
This function has no parameters.
true if the parameter is optional, otherwise false
true
false