Spec-Zone.ru › Laravel 11

ScheduleTestCommand

class ScheduleTestCommand extends Command (View source)

Свойства

CallsCommands
ConfiguresPrompts
HasParameters
InteractsWithIO
InteractsWithSignals
PromptsForMissingInput
Macroable

Свойства

protected Factory internal $components

Фабрика компонентов консоли.

from InteractsWithIO
protected InputInterface $input

Реализация интерфейса ввода.

from InteractsWithIO
protected OutputStyle $output

Реализация интерфейса вывода.

from InteractsWithIO
protected int $verbosity

Уровень детализации по умолчанию для команд вывода.

from InteractsWithIO
protected array $verbosityMap

Сопоставление удобочитаемых уровней детализации и OutputInterface Symfony.

from InteractsWithIO
protected Signals|null $signals

Экземпляр регистратора сигналов.

from InteractsWithSignals
static protected array $macros

Зарегистрированные макросы строк.

from Macroable
protected Application $laravel

Экземпляр приложения Laravel.

from Command
protected string $signature

Название команды консоли.

protected string $name

Название команды консоли.

from Command
protected string $description

Описание команды консоли.

protected string $help

Текст справки команды консоли.

from Command
protected bool $hidden

Указывает, должно ли быть отображено сообщение об ошибке.

from Command
protected bool $isolated

Указывает, может ли в данный момент выполняться только один экземпляр команды.

from Command
protected int $isolatedExitCode

Код возврата по умолчанию для изолированных команд.

from Command
protected array $aliases

Псевдонимы имени команды консоли.

from Command

Методы

Команда resolveCommand(Command|string $command)

Разрешить экземпляр командной строки для заданной команды.

из CallsCommands
int call(Command|string $command, array $arguments = [])

Вызвать другую команду консоли.

из CallsCommands
int callSilent(Command|string $command, array $arguments = [])

Вызвать другую команду консоли без вывода.

из CallsCommands
int callSilently(Command|string $command, array $arguments = [])

Вызвать другую команду консоли без вывода.

из CallsCommands
int runCommand(Command|string $command, array $arguments, OutputInterface $output)

Выполнить заданную команду консоли.

из CallsCommands
ArrayInput createInputFromArguments(array $arguments)

Создать экземпляр ввода из заданных аргументов.

из CallsCommands
массив context()

Получить весь контекст, переданный команде.

из CallsCommands
void configurePrompts(InputInterface $input)

Настроить подстановки подсказок.

из ConfiguresPrompts
mixed promptUntilValid(Closure $prompt, bool|string $required, Closure|null $validate)

Запрашивать у пользователя данные до тех пор, пока не пройдет проверка по заданному обрамлению.

из ConfiguresPrompts
?строка validatePrompt(mixed $value, mixed $rules)

Проверить значение заданной подсказки с помощью валидатора.

из ConfiguresPrompts
Validator getPromptValidatorInstance(mixed $field, mixed $value, mixed $rules, array $messages = [], array $attributes = [])

Получить экземпляр валидатора, который следует использовать для проверки подсказок.

из ConfiguresPrompts
массив validationMessages()

Получить сообщения об ошибках валидации, которые должны быть использованы во время проверки подсказок.

из ConfiguresPrompts
массив validationAttributes()

Получить атрибуты валидации, которые должны быть использованы при проверке подсказок.

из ConfiguresPrompts
void restorePrompts()

Восстановить вывод подсказок.

из ConfiguresPrompts
void specifyParameters()

Указать аргументы и параметры команды.

из HasParameters
массив getArguments()

Получить аргументы командной строки.

из HasParameters
массив getOptions()

Получить параметры командной строки.

из HasParameters
bool hasArgument(string|int $name)

Определить, присутствует ли заданный аргумент.

из InteractsWithIO
массив|строка|bool|null argument(string|null $key = null)

Получить значение аргумента команды.

из InteractsWithIO
массив arguments()

Получить все аргументы, переданные команде.

из InteractsWithIO
bool hasOption(string $name)

Определить, присутствует ли заданный параметр.

из InteractsWithIO
строка|массив|bool|null option(string|null $key = null)

Получить значение параметра команды.

из InteractsWithIO
массив options()

Получить все параметры, переданные команде.

из InteractsWithIO
bool confirm(string $question, bool $default = false)

Подтвердить вопрос у пользователя.

из InteractsWithIO
mixed ask(string $question, string|null $default = null)

Задать вопрос пользователю.

из InteractsWithIO
mixed anticipate(string $question, array|callable $choices, string|null $default = null)

Задать вопрос пользователю с автодополнением.

из InteractsWithIO
mixed askWithCompletion(string $question, array|callable $choices, string|null $default = null)

Задать вопрос пользователю с автодополнением.

из InteractsWithIO
mixed secret(string $question, bool $fallback = true)

Задать вопрос пользователю, но скрыть ответ в консоли.

из InteractsWithIO
строка|массив choice(string $question, array $choices, string|int|null $default = null, mixed|null $attempts = null, bool $multiple = false)

Предложить пользователю один вариант из списка ответов.

из InteractsWithIO
void table(array $headers, Arrayable|array $rows, TableStyle|string $tableStyle = 'default', array $columnStyles = [])

Форматировать ввод в текстовую таблицу.

из InteractsWithIO
mixed|void withProgressBar(iterable|int $totalSteps, Closure $callback)

Выполнить заданный обратный вызов с продвижением полосы прогресса.

из InteractsWithIO
void info(string $string, int|string|null $verbosity = null)

Вывести строку как информационное сообщение.

из InteractsWithIO
void line(string $string, string|null $style = null, int|string|null $verbosity = null)

Вывести строку как стандартный вывод.

из InteractsWithIO
void comment(string $string, int|string|null $verbosity = null)

Вывести строку как комментарий.

из InteractsWithIO
void question(string $string, int|string|null $verbosity = null)

Вывести строку как вопрос.

из InteractsWithIO
void error(string $string, int|string|null $verbosity = null)

Вывести строку как сообщение об ошибке.

из InteractsWithIO
void warn(string $string, int|string|null $verbosity = null)

Вывести строку как предупреждение.

из InteractsWithIO
void alert(string $string, int|string|null $verbosity = null)

Вывести строку в окне оповещения.

из InteractsWithIO
$this newLine(int $count = 1)

Вывести пустую строку.

из InteractsWithIO
void setInput(InputInterface $input)

Установить реализацию интерфейса ввода.

из InteractsWithIO
void setOutput(OutputStyle $output)

Установить реализацию интерфейса вывода.

из InteractsWithIO
void setVerbosity(string|int $level)

Установить уровень подробности.

из InteractsWithIO
int parseVerbosity(string|int|null $level = null)

Получить уровень подробности в терминах уровня OutputInterface Symfony.

из InteractsWithIO
OutputStyle getOutput()

Получить реализацию вывода.

из InteractsWithIO
Factory outputComponents()

Получить реализацию фабрики компонентов вывода.

из InteractsWithIO
trap($signals, $callback)

Без описания

из InteractsWithSignals
void untrap()

Отменить обработчики сигналов, установленные в обработчике команды.

из InteractsWithSignals
void interact(InputInterface $input, OutputInterface $output)

Взаимодействовать с пользователем перед проверкой ввода.

из PromptsForMissingInput
void promptForMissingArguments(InputInterface $input, OutputInterface $output)

Запросить у пользователя недостающие аргументы.

из PromptsForMissingInput
array promptForMissingArgumentsUsing()

Запрашивать недостающие аргументы ввода, используя возвращенные вопросы.

из PromptsForMissingInput
void afterPromptingForMissingArguments(InputInterface $input, OutputInterface $output)

Выполнить действия после того, как пользователя попросили о недостающих аргументах.

из PromptsForMissingInput
bool didReceiveOptions(InputInterface $input)

Является ли входной сигнал содержащим любые параметры, отличающиеся от значений по умолчанию.

из PromptsForMissingInput
static void macro(string $name, object|callable $macro)

Зарегистрировать пользовательскую макрокоманду.

из Macroable
static void mixin(object $mixin, bool $replace = true)

Смешать другой объект в класс.

из Macroable
static bool hasMacro(string $name)

Проверяет, зарегистрирована ли макрокоманда.

из Macroable
static void flushMacros()

Очистить существующие макрокоманды.

из Macroable
static mixed __callStatic(string $method, array $parameters)

Динамически обрабатывать вызовы класса.

из Macroable
mixed __call(string $method, array $parameters)

Динамически обрабатывать вызовы класса.

из Macroable
void __construct()

Создать новый экземпляр команды консоли.

из Command
void configureUsingFluentDefinition()

Настроить команду консоли с помощью определения fluent.

из Command
void configureIsolation()

Настроить команду консоли для изоляции.

из Command
int run(InputInterface $input, OutputInterface $output)

Запустить команду консоли.

из Command
int execute(InputInterface $input, OutputInterface $output)

Выполнить команду консоли.

из Command
CommandMutex commandIsolationMutex()

Получить экземпляр мьютекса изоляции команд для команды.

из Command
void fail(Throwable|string|null $exception = null)

Принудительно завершить команду с ошибкой.

из Command
bool isHidden()

{@inheritdoc}

из Command
Command setHidden(bool $hidden = true)

{@inheritdoc}

из Command
Application getLaravel()

Получить экземпляр приложения Laravel.

из Command
void setLaravel(Container $laravel)

Установить экземпляр приложения Laravel.

из Command
void handle(Schedule $schedule)

Выполнить команду консоли.

int getSelectedCommandByIndex(array $commandNames)

Получить выбранное имя команды по индексу.

Подробности

abstract protected Command resolveCommand(Command|string $command)

Разрешить экземпляр команды консоли для заданной команды.

Parameters

Command|string $command

Return Value

Command

int call(Command|string $command, array $arguments = [])

Вызвать другую команду консоли.

Parameters

Command|string $command
array $arguments

Return Value

int

int callSilent(Command|string $command, array $arguments = [])

Вызвать другую команду консоли без вывода.

Parameters

Command|string $command
array $arguments

Return Value

int

int callSilently(Command|string $command, array $arguments = [])

Вызвать другую команду консоли без вывода.

Parameters

Command|string $command
array $arguments

Return Value

int

protected int runCommand(Command|string $command, array $arguments, OutputInterface $output)

Запустить заданную команду консоли.

Parameters

Command|string $command
array $arguments
OutputInterface $output

Return Value

int

protected ArrayInput createInputFromArguments(array $arguments)

Создать экземпляр ввода из заданных аргументов.

Parameters

array $arguments

Return Value

ArrayInput

protected array context()

Получить весь контекст, переданный команде.

Return Value

array

protected void configurePrompts(InputInterface $input)

Настроить резервные варианты подсказок.

Parameters

InputInterface $input

Return Value

void

protected mixed promptUntilValid(Closure $prompt, bool|string $required, Closure|null $validate)

Запрашивать у пользователя, пока обратный вызов валидации не пройдет.

Parameters

Closure $prompt
bool|string $required
Closure|null $validate

Return Value

mixed

protected ?string validatePrompt(mixed $value, mixed $rules)

Проверить заданное значение подсказки с помощью валидатора.

Parameters

mixed $value
mixed $rules

Return Value

?string

protected Validator getPromptValidatorInstance(mixed $field, mixed $value, mixed $rules, array $messages = [], array $attributes = [])

Получить экземпляр валидатора, который следует использовать для проверки подсказок.

Parameters

mixed $field
mixed $value
mixed $rules
array $messages
array $attributes

Return Value

Validator
END_OF_DOCUMENT_MARKER

protected array validationMessages()

Получить сообщения об ошибках валидации, которые должны использоваться при валидации запроса.

Значение результата

array

protected array validationAttributes()

Получить атрибуты валидации, которые должны использоваться при валидации запроса.

Значение результата

array

protected void restorePrompts()

Восстановить вывод запросов.

Значение результата

void

protected void specifyParameters()

Указать аргументы и параметры команды.

Значение результата

void

protected array getArguments()

Получить аргументы командной строки.

Значение результата

array

protected array getOptions()

Получить параметры командной строки.

Значение результата

array

bool hasArgument(string|int $name)

Определить, присутствует ли данный аргумент.

Параметры

string|int $name

Значение результата

bool

array|string|bool|null argument(string|null $key = null)

Получить значение аргумента команды.

Параметры

string|null $key

Значение результата

array|string|bool|null

array arguments()

Получить все аргументы, переданные команде.

Значение результата

array

bool hasOption(string $name)

Определить, присутствует ли данный параметр.

Параметры

string $name

Значение результата

bool

string|array|bool|null option(string|null $key = null)

Получить значение параметра команды.

Параметры

string|null $key

Значение результата

string|array|bool|null

array options()

Получить все параметры, переданные команде.

Значение результата

array

bool confirm(string $question, bool $default = false)

Подтвердить вопрос у пользователя.

Параметры

string $question
bool $default

Значение результата

bool

mixed ask(string $question, string|null $default = null)

Запросить ввод у пользователя.

Параметры

string $question
string|null $default

Значение результата

mixed

mixed anticipate(string $question, array|callable $choices, string|null $default = null)

Запросить ввод у пользователя с автодополнением.

Параметры

string $question
array|callable $choices
string|null $default

Значение результата

mixed

mixed askWithCompletion(string $question, array|callable $choices, string|null $default = null)

Запросить ввод у пользователя с автодополнением.

Параметры

string $question
array|callable $choices
string|null $default

Значение результата

mixed

mixed secret(string $question, bool $fallback = true)

Запросить ввод у пользователя, но скрыть ответ в консоли.

Параметры

string $question
bool $fallback

Значение результата

mixed

string|array choice(string $question, array $choices, string|int|null $default = null, mixed|null $attempts = null, bool $multiple = false)

Предложить пользователю выбрать один вариант из массива ответов.

Параметры

string $question
array $choices
string|int|null $default
mixed|null $attempts
bool $multiple

Значение результата

string|array

void table(array $headers, Arrayable|array $rows, TableStyle|string $tableStyle = 'default', array $columnStyles = [])

Форматировать ввод в текстовую таблицу.

Параметры

array $headers
Arrayable|array $rows
TableStyle|string $tableStyle
array $columnStyles

Значение результата

void

mixed|void withProgressBar(iterable|int $totalSteps, Closure $callback)

Выполнить заданный обратный вызов с отображением прогресс-бара.

Параметры

iterable|int $totalSteps
Closure $callback

Значение результата

mixed|void

void info(string $string, int|string|null $verbosity = null)

Вывести строку в качестве информационного вывода.

Параметры

string $string
int|string|null $verbosity

Значение результата

void

void line(string $string, string|null $style = null, int|string|null $verbosity = null)

Вывести строку в стандартный вывод.

Параметры

string $string
string|null $style
int|string|null $verbosity

Возвращаемое значение

void

void comment(string $string, int|string|null $verbosity = null)

Вывести строку в качестве комментария.

Параметры

string $string
int|string|null $verbosity

Возвращаемое значение

void

void question(string $string, int|string|null $verbosity = null)

Вывести строку в качестве вопроса.

Параметры

string $string
int|string|null $verbosity

Возвращаемое значение

void

void error(string $string, int|string|null $verbosity = null)

Вывести строку в качестве сообщения об ошибке.

Параметры

string $string
int|string|null $verbosity

Возвращаемое значение

void

void warn(string $string, int|string|null $verbosity = null)

Вывести строку в качестве предупреждения.

Параметры

string $string
int|string|null $verbosity

Возвращаемое значение

void

void alert(string $string, int|string|null $verbosity = null)

Вывести строку в информационном окне.

Параметры

string $string
int|string|null $verbosity

Возвращаемое значение

void

$this newLine(int $count = 1)

Вывести пустую строку.

Параметры

int $count

Возвращаемое значение

$this

void setInput(InputInterface $input)

Установить реализацию интерфейса ввода.

Параметры

InputInterface $input

Возвращаемое значение

void

void setOutput(OutputStyle $output)

Установить реализацию интерфейса вывода.

Параметры

OutputStyle $output

Возвращаемое значение

void

protected void setVerbosity(string|int $level)

Установить уровень подробности.

Параметры

string|int $level

Возвращаемое значение

void

protected int parseVerbosity(string|int|null $level = null)

Получить уровень подробности в терминах уровня OutputInterface Symfony.

Параметры

string|int|null $level

Возвращаемое значение

int

OutputStyle getOutput()

Получить реализацию вывода.

Возвращаемое значение

OutputStyle

Factory outputComponents()

Получить реализацию фабрики компонентов вывода.

Возвращаемое значение

Factory

trap($signals, $callback)

Без описания

Параметры

$signals
$callback

void untrap()

internal

Отменить обработчики сигналов, установленные в обработчике команды.

Возвращаемое значение

void

protected void interact(InputInterface $input, OutputInterface $output)

Взаимодействовать с пользователем перед проверкой ввода.

Параметры

InputInterface $input
OutputInterface $output

Возвращаемое значение

void

protected void promptForMissingArguments(InputInterface $input, OutputInterface $output)

Запросить у пользователя отсутствующие аргументы.

Параметры

InputInterface $input
OutputInterface $output

Возвращаемое значение

void

protected array promptForMissingArgumentsUsing()

Запросить отсутствующие аргументы ввода, используя возвращаемые вопросы.

Возвращаемое значение

array

protected void afterPromptingForMissingArguments(InputInterface $input, OutputInterface $output)

Выполнить действия после того, как пользователя попросили предоставить недостающие аргументы.

Параметры

InputInterface $input
OutputInterface $output

Возвращаемое значение

void

protected bool didReceiveOptions(InputInterface $input)

Является ли входной сигнал содержащим опции, отличающиеся от значений по умолчанию.

Параметры

InputInterface $input

Возвращаемое значение

bool

static void macro(string $name, object|callable $macro)

Зарегистрировать пользовательский макрос.

Параметры

string $name
object|callable $macro

Возвращаемое значение

void

static void mixin(object $mixin, bool $replace = true)

Смешать другой объект в класс.

Parameters

object $mixin
bool $replace

Return Value

void

Exceptions

ReflectionException

static bool hasMacro(string $name)

Проверяет, зарегистрирован ли макрос.

Parameters

string $name

Return Value

bool

static void flushMacros()

Очистить существующие макросы.

Return Value

void

static mixed __callStatic(string $method, array $parameters)

Динамически обрабатывать вызовы класса.

Parameters

string $method
array $parameters

Return Value

mixed

Exceptions

BadMethodCallException

mixed __call(string $method, array $parameters)

Динамически обрабатывать вызовы класса.

Parameters

string $method
array $parameters

Return Value

mixed

Exceptions

BadMethodCallException

void __construct()

Создать новый экземпляр команды консоли.

Return Value

void

protected void configureUsingFluentDefinition()

Настроить команду консоли с помощью определения fluent.

Return Value

void

protected void configureIsolation()

Настроить команду консоли для изоляции.

Return Value

void

int run(InputInterface $input, OutputInterface $output)

Запустить команду консоли.

Parameters

InputInterface $input
OutputInterface $output

Return Value

int

protected int execute(InputInterface $input, OutputInterface $output)

Выполнить команду консоли.

Parameters

InputInterface $input
OutputInterface $output

Return Value

int

protected CommandMutex commandIsolationMutex()

Получить экземпляр мьютекса изоляции команды для команды.

Return Value

CommandMutex

void fail(Throwable|string|null $exception = null)

Отказаться от команды вручную.

Parameters

Throwable|string|null $exception

Return Value

void

Exceptions

Throwable

bool isHidden()

{@inheritdoc}

Return Value

bool

Command setHidden(bool $hidden = true)

{@inheritdoc}

Parameters

bool $hidden

Return Value

Command

Application getLaravel()

Получить экземпляр приложения Laravel.

Return Value

Application

void setLaravel(Container $laravel)

Установить экземпляр приложения Laravel.

Parameters

Container $laravel

Return Value

void

void handle(Schedule $schedule)

Выполнить команду консоли.

Parameters

Schedule $schedule

Return Value

void

protected int getSelectedCommandByIndex(array $commandNames)

Получить выбранное имя команды по индексу.

Parameters

array $commandNames

Return Value

int

© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/11.x/Illuminate/Console/Scheduling/ScheduleTestCommand.html

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API