class JobsCommand extends ConsoleCommand

Queue jobs list command

Properties

protected SymfonyStyle $style Style obj reference from ConsoleCommand
protected bool $default Set to true for default command from ConsoleCommand
protected Table $table Table output from ConsoleCommand
protected EventDispatcher $dispatcher Event dispatcher from ConsoleCommand
protected string|null $outputType Output type from ConsoleCommand
protected array $result Command result data from ConsoleCommand

Methods

__construct(string|null $name = null, string|null $description = null)

Constructor

void
setOutputType(string|null $outputType)

Set output type

array
getResult()

Get execution result

boolean
isConsoleOutput()

Return true if output is to console

void
setDispatcher(object $dispatcher)

Set event dispatcher

mixed
executeCommand(InputInterface $input, OutputInterface $output)

Run command

mixed
run(InputInterface $input, OutputInterface $output)

Run method wrapper

void
addRequiredArgument(string $name, string $description = '', mixed|null $default = null)

Add required argument

void
addOptionalArgument(string $name, string $description = '', mixed|null $default = null)

Add optional argument

void
addOptionalOption(string $name, string $description = '', mixed|null $default = null)

Add optional option

mixed
execute(InputInterface $input, OutputInterface $output)

Run console command

Table
table()

Get table obj

void
setDefault(bool $default = true)

Set command as default

bool
isDefault()

Return true if command is default.

void
showTitle(string|null $title = null, string $space = ' ')

Show command title

void
showError(string $message, string $label = 'Error:', string $space = ' ')

Show error message

void
showErrors(string|array $errors, string $label = 'Error:', string $space = ' ')

Show multipel errors

void
showErrorDetails(string|array $details, string $space = ' ')

Show error details

void
checkMark(string $space = ' ')

Show CHECK MARK

void
newLine()

New line

void
showCompleted(string|null $label = null, string $space = ' ')

Show 'done' message

void
writeField(string $label, mixed $value, string $color = 'cyan', string $space = ' ')

Write field

void
writeFieldLn(string $label, mixed $value, string $color = 'cyan', string $space = ' ')

Write field

void
writeLn(string $text, string $space = ' ', string|null $color = null)

Write line

void
configure()

Configure command

Details

in ConsoleCommand at line 77
__construct(string|null $name = null, string|null $description = null)

Constructor

Parameters

string|null $name
string|null $description

in ConsoleCommand at line 97
void setOutputType(string|null $outputType)

Set output type

Parameters

string|null $outputType

Return Value

void

in ConsoleCommand at line 107
array getResult()

Get execution result

Return Value

array

in ConsoleCommand at line 117
boolean isConsoleOutput()

Return true if output is to console

Return Value

boolean

in ConsoleCommand at line 128
void setDispatcher(object $dispatcher)

Set event dispatcher

Parameters

object $dispatcher

Return Value

void

at line 41
protected mixed executeCommand(InputInterface $input, OutputInterface $output)

Run command

Parameters

InputInterface $input
OutputInterface $output

Return Value

mixed

in ConsoleCommand at line 149
mixed run(InputInterface $input, OutputInterface $output)

Run method wrapper

Parameters

InputInterface $input
OutputInterface $output

Return Value

mixed

in ConsoleCommand at line 175
void addRequiredArgument(string $name, string $description = '', mixed|null $default = null)

Add required argument

Parameters

string $name
string $description
mixed|null $default

Return Value

void

in ConsoleCommand at line 188
void addOptionalArgument(string $name, string $description = '', mixed|null $default = null)

Add optional argument

Parameters

string $name
string $description
mixed|null $default

Return Value

void

in ConsoleCommand at line 201
void addOptionalOption(string $name, string $description = '', mixed|null $default = null)

Add optional option

Parameters

string $name
string $description
mixed|null $default

Return Value

void

in ConsoleCommand at line 213
protected mixed execute(InputInterface $input, OutputInterface $output)

Run console command

Parameters

InputInterface $input
OutputInterface $output

Return Value

mixed

in ConsoleCommand at line 225
Table table()

Get table obj

Return Value

Table

in ConsoleCommand at line 236
void setDefault(bool $default = true)

Set command as default

Parameters

bool $default

Return Value

void

in ConsoleCommand at line 246
bool isDefault()

Return true if command is default.

Return Value

bool

in ConsoleCommand at line 258
void showTitle(string|null $title = null, string $space = ' ')

Show command title

Parameters

string|null $title
string $space

Return Value

void

in ConsoleCommand at line 281
void showError(string $message, string $label = 'Error:', string $space = ' ')

Show error message

Parameters

string $message
string $label
string $space

Return Value

void

in ConsoleCommand at line 296
void showErrors(string|array $errors, string $label = 'Error:', string $space = ' ')

Show multipel errors

Parameters

string|array $errors
string $label
string $space

Return Value

void

in ConsoleCommand at line 315
void showErrorDetails(string|array $details, string $space = ' ')

Show error details

Parameters

string|array $details
string $space

Return Value

void

in ConsoleCommand at line 333
void checkMark(string $space = ' ')

Show CHECK MARK

Parameters

string $space

Return Value

void

in ConsoleCommand at line 343
void newLine()

New line

Return Value

void

in ConsoleCommand at line 355
void showCompleted(string|null $label = null, string $space = ' ')

Show 'done' message

Parameters

string|null $label
string $space

Return Value

void

in ConsoleCommand at line 372
void writeField(string $label, mixed $value, string $color = 'cyan', string $space = ' ')

Write field

Parameters

string $label
mixed $value
string $color
string $space

Return Value

void

in ConsoleCommand at line 389
void writeFieldLn(string $label, mixed $value, string $color = 'cyan', string $space = ' ')

Write field

Parameters

string $label
mixed $value
string $color
string $space

Return Value

void

in ConsoleCommand at line 403
void writeLn(string $text, string $space = ' ', string|null $color = null)

Write line

Parameters

string $text
string $space
string|null $color

Return Value

void

at line 29
protected void configure()

Configure command

Return Value

void