File tree 1 file changed +10
-2
lines changed
components/console/helpers
1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,11 @@ number of units, and advance the progress as the command executes::
42
42
Instead of advancing the bar by a number of steps (with the
43
43
:method: `Symfony\\ Component\\ Console\\ Helper\\ ProgressBar::advance ` method),
44
44
you can also set the current progress by calling the
45
- :method: `Symfony\\ Component\\ Console\\ Helper\\ ProgressBar::setCurrent ` method.
45
+ :method: `Symfony\\ Component\\ Console\\ Helper\\ ProgressBar::setProgress ` method.
46
+
47
+ .. versionadded :: 2.6
48
+ The ``setProgress() `` method was introduced in Symfony 2.6. Previously it was
49
+ called ``setCurrent() ``.
46
50
47
51
.. caution ::
48
52
@@ -300,10 +304,14 @@ that displays the number of remaining steps::
300
304
ProgressBar::setPlaceholderFormatterDefinition(
301
305
'remaining_steps',
302
306
function (ProgressBar $bar, OutputInterface $output) {
303
- return $bar->getMaxSteps() - $bar->getStep ();
307
+ return $bar->getMaxSteps() - $bar->getProgress ();
304
308
}
305
309
);
306
310
311
+ .. versionadded :: 2.6
312
+ The ``getProgress() `` method was introduced in Symfony 2.6. Previously it was
313
+ called ``getStep() ``.
314
+
307
315
Custom Messages
308
316
~~~~~~~~~~~~~~~
309
317
You can’t perform that action at this time.
0 commit comments