File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 66
77class LineView extends View
88{
9- protected string $ streamName = 'php://stdout ' ;
10-
119 public function newLine (int $ count = 1 ): void
1210 {
1311 for ($ i = 0 ; $ i < $ count ; $ i ++) {
Original file line number Diff line number Diff line change @@ -16,8 +16,6 @@ class ProgressBarView extends View
1616
1717 protected int $ total = 100 ;
1818
19- protected string $ streamName = 'php://stderr ' ;
20-
2119 public function create (int $ total ): static
2220 {
2321 $ this ->total = max (1 , $ total );
Original file line number Diff line number Diff line change 1414
1515class TableView extends View
1616{
17- protected string $ streamName = 'php://stdout ' ;
18-
1917 public function show (array $ data ): void
2018 {
2119 $ headers = $ this ->headers ($ data );
Original file line number Diff line number Diff line change @@ -12,8 +12,6 @@ abstract class View
1212 /** @var resource|null */
1313 protected static mixed $ stream = null ;
1414
15- protected string $ streamName ;
16-
1715 protected function writeLine (string $ line ): void
1816 {
1917 fwrite ($ this ->stream (), $ line . PHP_EOL );
@@ -29,6 +27,6 @@ protected function write(string $line): void
2927 */
3028 protected function stream ()
3129 {
32- return static ::$ stream ??= fopen ($ this -> streamName , 'wb ' );
30+ return static ::$ stream ??= fopen (' php://stderr ' , 'wb ' );
3331 }
3432}
You can’t perform that action at this time.
0 commit comments