1 | <?php |
||
16 | class DumpServerCommand extends Command |
||
17 | { |
||
18 | /** |
||
19 | * The console command name. |
||
20 | * |
||
21 | * @var string |
||
22 | */ |
||
23 | protected $signature = 'dump-server {--format=cli : The output format (cli,html).}'; |
||
24 | |||
25 | /** |
||
26 | * The console command description. |
||
27 | * |
||
28 | * @var string |
||
29 | */ |
||
30 | protected $description = 'Start the dump server to collect dump information.'; |
||
31 | |||
32 | /** |
||
33 | * The Dump server. |
||
34 | * |
||
35 | * @var \Symfony\Component\VarDumper\Server\DumpServer |
||
36 | */ |
||
37 | private $server; |
||
38 | |||
39 | /** |
||
40 | * DumpServerCommand constructor. |
||
41 | * |
||
42 | * @param \Symfony\Component\VarDumper\Server\DumpServer $server |
||
43 | * @return void |
||
|
|||
44 | */ |
||
45 | public function __construct(DumpServer $server) |
||
51 | |||
52 | /** |
||
53 | * Handle the command. |
||
54 | * |
||
55 | * @return void |
||
56 | */ |
||
57 | public function handle() |
||
85 | |||
86 | /** |
||
87 | * Share the contents of the dump. |
||
88 | * |
||
89 | * @param \Symfony\Component\VarDumper\Cloner\Data $data |
||
90 | * @param array $context |
||
91 | * @param int $clientId |
||
92 | * |
||
93 | * @return void |
||
94 | */ |
||
95 | protected function share(Data $data, array $context, int $clientId) |
||
99 | } |
||
100 |
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.