Total Complexity | 3 |
Total Lines | 59 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | class BlockMake extends Command |
||
8 | { |
||
9 | /** |
||
10 | * The name and signature of the console command. |
||
11 | * |
||
12 | * @var string |
||
13 | */ |
||
14 | protected $signature = |
||
15 | 'twill:make:block ' . |
||
16 | '{name : Name of the new block.} ' . |
||
17 | '{base? : Block on which the new block should be based.}' . |
||
18 | '{icon? : Icon for the new block. List icons using the twill:list:icons command.}'; |
||
19 | /** |
||
20 | * The console command description. |
||
21 | * |
||
22 | * @var string |
||
23 | */ |
||
24 | protected $description = 'Create a new block'; |
||
25 | |||
26 | /** |
||
27 | * @var \A17\Twill\Services\Blocks\BlockMaker |
||
28 | */ |
||
29 | protected $blockMaker; |
||
30 | |||
31 | /** |
||
32 | * @param \A17\Twill\Services\Blocks\BlockMaker |
||
33 | */ |
||
34 | 69 | public function __construct(BlockMaker $blockMaker) |
|
39 | 69 | } |
|
40 | |||
41 | /** |
||
42 | * @return \A17\Twill\Services\Blocks\BlockMaker |
||
43 | */ |
||
44 | 5 | public function getBlockMaker(): \A17\Twill\Services\Blocks\BlockMaker |
|
45 | { |
||
46 | 5 | return $this->blockMaker; |
|
47 | } |
||
48 | |||
49 | /** |
||
50 | * Executes the console command. |
||
51 | * |
||
52 | * @return mixed |
||
53 | * @throws \Exception |
||
54 | */ |
||
55 | 5 | public function handle() |
|
66 | } |
||
67 | } |
||
68 |