ProgressIndicator
in package
Tags
Table of Contents
Properties
- $format : mixed
- $formats : mixed
- $formatters : mixed
- $indicatorChangeInterval : mixed
- $indicatorCurrent : mixed
- $indicatorUpdateTime : mixed
- $indicatorValues : mixed
- $message : mixed
- $output : mixed
- $started : mixed
- $startTime : mixed
Methods
- __construct() : mixed
- advance() : mixed
- Advances the indicator.
- finish() : mixed
- Finish the indicator with message.
- getFormatDefinition() : string|null
- Gets the format for a given name.
- getPlaceholderFormatterDefinition() : callable|null
- Gets the placeholder formatter for a given name.
- setMessage() : mixed
- Sets the current indicator message.
- setPlaceholderFormatterDefinition() : mixed
- Sets a placeholder formatter for a given name.
- start() : mixed
- Starts the indicator output.
- determineBestFormat() : string
- display() : mixed
- getCurrentTimeInMilliseconds() : float
- initFormats() : array<string|int, mixed>
- initPlaceholderFormatters() : array<string|int, mixed>
- overwrite() : mixed
- Overwrites a previous message to the output.
Properties
$format
private
mixed
$format
$formats
private
static mixed
$formats
$formatters
private
static mixed
$formatters
$indicatorChangeInterval
private
mixed
$indicatorChangeInterval
$indicatorCurrent
private
mixed
$indicatorCurrent
$indicatorUpdateTime
private
mixed
$indicatorUpdateTime
$indicatorValues
private
mixed
$indicatorValues
$message
private
mixed
$message
$output
private
mixed
$output
$started
private
mixed
$started
= false
$startTime
private
mixed
$startTime
Methods
__construct()
public
__construct(OutputInterface $output[, string|null $format = null ][, int $indicatorChangeInterval = 100 ][, array<string|int, mixed>|null $indicatorValues = null ]) : mixed
Parameters
- $output : OutputInterface
- $format : string|null = null
-
Indicator format
- $indicatorChangeInterval : int = 100
-
Change interval in milliseconds
- $indicatorValues : array<string|int, mixed>|null = null
-
Animated indicator characters
advance()
Advances the indicator.
public
advance() : mixed
finish()
Finish the indicator with message.
public
finish(mixed $message) : mixed
Parameters
- $message : mixed
getFormatDefinition()
Gets the format for a given name.
public
static getFormatDefinition(string $name) : string|null
Parameters
- $name : string
-
The format name
Return values
string|null —A format string
getPlaceholderFormatterDefinition()
Gets the placeholder formatter for a given name.
public
static getPlaceholderFormatterDefinition(string $name) : callable|null
Parameters
- $name : string
-
The placeholder name (including the delimiter char like %)
Return values
callable|null —A PHP callable
setMessage()
Sets the current indicator message.
public
setMessage(string|null $message) : mixed
Parameters
- $message : string|null
setPlaceholderFormatterDefinition()
Sets a placeholder formatter for a given name.
public
static setPlaceholderFormatterDefinition(string $name, callable $callable) : mixed
This method also allow you to override an existing placeholder.
Parameters
- $name : string
-
The placeholder name (including the delimiter char like %)
- $callable : callable
-
A PHP callable
start()
Starts the indicator output.
public
start(mixed $message) : mixed
Parameters
- $message : mixed
determineBestFormat()
private
determineBestFormat() : string
Return values
stringdisplay()
private
display() : mixed
getCurrentTimeInMilliseconds()
private
getCurrentTimeInMilliseconds() : float
Return values
floatinitFormats()
private
static initFormats() : array<string|int, mixed>
Return values
array<string|int, mixed>initPlaceholderFormatters()
private
static initPlaceholderFormatters() : array<string|int, mixed>
Return values
array<string|int, mixed>overwrite()
Overwrites a previous message to the output.
private
overwrite(string $message) : mixed
Parameters
- $message : string