SelectOption
class SelectOption implements Arrayable
Properties
| protected TextObject | $text | The option text. |
|
| protected string | $value | The option value. |
Methods
__construct(string $text, Stringable|string|int|float|bool $value)
Create a new select option instance.
void
text(string $text)
Set the option's text value.
void
array
toArray()
Convert the select option to an array.
Details
at line 27
__construct(string $text, Stringable|string|int|float|bool $value)
Create a new select option instance.
at line 36
protected void
text(string $text)
Set the option's text value.
at line 44
protected void
value(Stringable|string|int|float|bool $value)
Set the option's value.
at line 62
array
toArray()
Convert the select option to an array.