equal
deleted
inserted
replaced
|
1 <?php |
|
2 |
|
3 /* |
|
4 * This file is part of the Symfony package. |
|
5 * |
|
6 * (c) Fabien Potencier <fabien@symfony.com> |
|
7 * |
|
8 * For the full copyright and license information, please view the LICENSE |
|
9 * file that was distributed with this source code. |
|
10 */ |
|
11 |
|
12 namespace Symfony\Component\Console\Output; |
|
13 |
|
14 use Symfony\Component\Console\Formatter\OutputFormatter; |
|
15 |
|
16 /** |
|
17 * ConsoleOutput is the default class for all CLI output. It uses STDOUT. |
|
18 * |
|
19 * This class is a convenient wrapper around `StreamOutput`. |
|
20 * |
|
21 * $output = new ConsoleOutput(); |
|
22 * |
|
23 * This is equivalent to: |
|
24 * |
|
25 * $output = new StreamOutput(fopen('php://stdout', 'w')); |
|
26 * |
|
27 * @author Fabien Potencier <fabien@symfony.com> |
|
28 * |
|
29 * @api |
|
30 */ |
|
31 class ConsoleOutput extends StreamOutput |
|
32 { |
|
33 /** |
|
34 * Constructor. |
|
35 * |
|
36 * @param integer $verbosity The verbosity level (self::VERBOSITY_QUIET, self::VERBOSITY_NORMAL, |
|
37 * self::VERBOSITY_VERBOSE) |
|
38 * @param Boolean $decorated Whether to decorate messages or not (null for auto-guessing) |
|
39 * @param OutputFormatter $formatter Output formatter instance |
|
40 * |
|
41 * @api |
|
42 */ |
|
43 public function __construct($verbosity = self::VERBOSITY_NORMAL, $decorated = null, OutputFormatter $formatter = null) |
|
44 { |
|
45 parent::__construct(fopen('php://stdout', 'w'), $verbosity, $decorated, $formatter); |
|
46 } |
|
47 } |