ChoiceQuestion
class ChoiceQuestion extends Question
Represents a choice question.
Methods
No description
In case the response can not be hidden, whether to fallback on non-hidden question or not.
Sets whether to fallback on non-hidden question if the response can not be hidden.
Sets values for the autocompleter.
Returns available choices.
Sets multiselect option.
Returns whether the choices are multiselect.
Gets the prompt for choices.
Sets the prompt for choices.
Sets the error message for invalid values.
Details
bool
isHiddenFallback()
In case the response can not be hidden, whether to fallback on non-hidden question or not.
$this
setHiddenFallback(bool $fallback)
Sets whether to fallback on non-hidden question if the response can not be hidden.
$this
setMaxAttempts(int|null $attempts)
Sets the maximum number of attempts.
Null means an unlimited number of attempts.
int|null
getMaxAttempts()
Gets the maximum number of attempts.
Null means an unlimited number of attempts.
$this
setNormalizer(callable $normalizer)
Sets a normalizer for the response.
The normalizer can be a callable (a string), a closure or a class implementing __invoke.
callable
getNormalizer()
Gets the normalizer for the response.
The normalizer can ba a callable (a string), a closure or a class implementing __invoke.