You are here

public function ProgressBar::start in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/console/Helper/ProgressBar.php \Symfony\Component\Console\Helper\ProgressBar::start()

Starts the progress output.

Parameters

int|null $max Number of steps to complete the bar (0 if indeterminate), null to leave unchanged:

File

vendor/symfony/console/Helper/ProgressBar.php, line 331

Class

ProgressBar
The ProgressBar provides helpers to display progress output.

Namespace

Symfony\Component\Console\Helper

Code

public function start($max = null) {
  $this->startTime = time();
  $this->step = 0;
  $this->percent = 0.0;
  if (null !== $max) {
    $this
      ->setMaxSteps($max);
  }
  $this
    ->display();
}