Permalink
Browse files

bug #4010 [Console] Fixed documentation for ProgressBar (VasekPurchart)

This PR was merged into the 2.5 branch.

Discussion
----------

[Console] Fixed documentation for ProgressBar

This place is using the old ProgressHelper API and can be confusing when migrating.

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | no
| Applies to    | 2.5+
| Fixed tickets | no

Commits
-------

4bc00df Fixed documentation for ProgressBar
  • Loading branch information...
weaverryan committed Jul 25, 2014
2 parents 12752c1 + 4bc00df commit 99932cf0f98c15e0504a41867046b374305865d3
Showing with 3 additions and 2 deletions.
  1. +3 −2 components/console/helpers/progressbar.rst
@@ -265,10 +265,11 @@ to display it can be customized::
For performance reasons, be careful if you set the total number of steps
to a high number. For example, if you're iterating over a large number of
items, consider setting the redraw frequency to a higher value by calling
:method:`Symfony\\Component\\Console\\Helper\\ProgressHelper::setRedrawFrequency`,
:method:`Symfony\\Component\\Console\\Helper\\ProgressBar::setRedrawFrequency`,
so it updates on only some iterations::
$progress->start($output, 50000);
$progress = new ProgressBar($output, 50000);
$progress->start();
// update every 100 iterations
$progress->setRedrawFrequency(100);

0 comments on commit 99932cf

Please sign in to comment.