class SymfonyStyle extends OutputStyle
Output decorator helpers for the Symfony Style Guide.
MAX_LINE_LENGTH |
__construct(InputInterface $input, OutputInterface $output) | ||
newLine(int $count = 1) Add newline(s). | ||
ProgressBar | createProgressBar(int $max) | |
write(string|array $messages, bool $newline = false, $type = self::OUTPUT_NORMAL) Writes a message to the output. | ||
writeln(string|array $messages, $type = self::OUTPUT_NORMAL) Writes a message to the output and adds a newline at the end. | ||
setVerbosity(int $level) Sets the verbosity of the output. | from OutputStyle | |
int | getVerbosity() Gets the current verbosity of the output. | from OutputStyle |
setDecorated(bool $decorated) Sets the decorated flag. | from OutputStyle | |
bool | isDecorated() Gets the decorated flag. | from OutputStyle |
setFormatter(OutputFormatterInterface $formatter) Sets output formatter. | from OutputStyle | |
OutputFormatterInterface | getFormatter() Returns current output formatter instance. | from OutputStyle |
block(string|array $messages, string|null $type = null, string|null $style = null, string $prefix = ' ', bool $padding = false) Formats a message as a block of text. | ||
title(string $message) Formats a command title. | ||
section(string $message) Formats a section title. | ||
listing(array $elements) Formats a list. | ||
text(string|array $message) Formats informational text. | ||
comment($message) {@inheritdoc} | ||
success(string|array $message) Formats a success result bar. | ||
error(string|array $message) Formats an error result bar. | ||
warning(string|array $message) Formats an warning result bar. | ||
note(string|array $message) Formats a note admonition. | ||
caution(string|array $message) Formats a caution admonition. | ||
table(array $headers, array $rows) Formats a table. | ||
string | ask(string $question, string|null $default = null, callable|null $validator = null) Asks a question. | |
string | askHidden(string $question, callable|null $validator = null) Asks a question with the user input hidden. | |
bool | confirm(string $question, bool $default = true) Asks for confirmation. | |
string | choice(string $question, array $choices, string|int|null $default = null) Asks a choice question. | |
progressStart(int $max) Starts the progress output. | ||
progressAdvance(int $step = 1) Advances the progress output X steps. | ||
progressFinish() Finishes the progress output. | ||
string | askQuestion(Question $question) |
Add newline(s).
Writes a message to the output.
Writes a message to the output and adds a newline at the end.
Sets the verbosity of the output.
Gets the current verbosity of the output.
Sets the decorated flag.
Gets the decorated flag.
Sets output formatter.
Returns current output formatter instance.
Formats a message as a block of text.
Formats a command title.
Formats a section title.
Formats a list.
Formats informational text.
{@inheritdoc}
Formats a success result bar.
Formats an error result bar.
Formats an warning result bar.
Formats a note admonition.
Formats a caution admonition.
Formats a table.
Asks a question.
Asks a question with the user input hidden.
Asks for confirmation.
Asks a choice question.
Starts the progress output.
Advances the progress output X steps.
Finishes the progress output.
© 2004–2016 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/3.0/Symfony/Component/Console/Style/SymfonyStyle.html