Text UI
A simple and fast way to take user input and display output in text mode using PHP.
|
Public Member Functions | |
__construct (string $label) | |
read () | |
Public Member Functions inherited from EntryInterface |
Protected Attributes | |
readonly string | $label |
User text input.
Displays a message to the user and returns the text the user entered. When the user presses ENTER, the raw text entered is fed to the trim() function and returned.
The label is displayed on the same line as the entry point. This means that if you want to display the label above the input space, add a line break at the end of $label. The same goes for whitespace and tabs.
Definition at line 18 of file TextEntry.php.
__construct | ( | string | $label | ) |
Definition at line 22 of file TextEntry.php.
read | ( | ) |
Displays the label and waits for user input.
Implements EntryInterface.
Definition at line 32 of file TextEntry.php.
|
protected |
Definition at line 20 of file TextEntry.php.