Pionia Core

OutputStyle extends SymfonyStyle
in package
implements NewLineAware

Table of Contents

Interfaces

NewLineAware

Properties

$newLinesWritten  : int
The number of trailing new lines written by the last output.
$output  : OutputInterface
The output instance.

Methods

__construct()  : void
Create a new Console OutputStyle instance.
askQuestion()  : mixed
getOutput()  : OutputInterface
Get the underlying Symfony output implementation.
isDebug()  : bool
Returns whether verbosity is debug (-vvv).
isQuiet()  : bool
Returns whether verbosity is quiet (-q).
isVerbose()  : bool
Returns whether verbosity is verbose (-v).
isVeryVerbose()  : bool
Returns whether verbosity is very verbose (-vv).
newLine()  : void
{@inheritdoc}
newLinesWritten()  : int
How many trailing newlines were written.
write()  : void
writeln()  : void
{@inheritdoc}
trailingNewLineCount()  : int

Properties

$newLinesWritten

The number of trailing new lines written by the last output.

protected int $newLinesWritten = 1

This is initialized as 1 to account for the new line written by the shell after executing a command.

$output

The output instance.

private OutputInterface $output

Methods

__construct()

Create a new Console OutputStyle instance.

public __construct(InputInterface $input, OutputInterface $output) : void
Parameters
$input : InputInterface
$output : OutputInterface

askQuestion()

public askQuestion(Question $question) : mixed
Parameters
$question : Question

getOutput()

Get the underlying Symfony output implementation.

public getOutput() : OutputInterface
Return values
OutputInterface

isDebug()

Returns whether verbosity is debug (-vvv).

public isDebug() : bool
Return values
bool

isQuiet()

Returns whether verbosity is quiet (-q).

public isQuiet() : bool
Return values
bool

isVerbose()

Returns whether verbosity is verbose (-v).

public isVerbose() : bool
Return values
bool

isVeryVerbose()

Returns whether verbosity is very verbose (-vv).

public isVeryVerbose() : bool
Return values
bool

newLine()

{@inheritdoc}

public newLine([int $count = 1 ]) : void
Parameters
$count : int = 1

newLinesWritten()

How many trailing newlines were written.

public newLinesWritten() : int
Return values
int

write()

public write(string|iterable<string|int, mixed> $messages[, bool $newline = false ][, int $options = 0 ]) : void
Parameters
$messages : string|iterable<string|int, mixed>
$newline : bool = false
$options : int = 0

writeln()

{@inheritdoc}

public writeln(string|iterable<string|int, mixed> $messages[, int $type = self::OUTPUT_NORMAL ]) : void
Parameters
$messages : string|iterable<string|int, mixed>
$type : int = self::OUTPUT_NORMAL

trailingNewLineCount()

protected trailingNewLineCount(mixed $messages) : int
Parameters
$messages : mixed
Return values
int

        
On this page

Search results