1 | <?php |
||
13 | class PHPCrafter implements CrafterInterface |
||
14 | { |
||
15 | /** |
||
16 | * Stub file generator. |
||
17 | * |
||
18 | * @var FileGenerator |
||
19 | */ |
||
20 | protected $stubber; |
||
21 | |||
22 | /** |
||
23 | * @var Filesystem |
||
24 | */ |
||
25 | private $filesystem; |
||
26 | |||
27 | /** |
||
28 | * PHPCrafter constructor. |
||
29 | * |
||
30 | * @param FileGenerator $stubber |
||
31 | * @param Filesystem $filesystem |
||
32 | */ |
||
33 | 6 | public function __construct(FileGenerator $stubber, Filesystem $filesystem) |
|
38 | |||
39 | /** |
||
40 | * Craft the application with parameters. |
||
41 | * |
||
42 | * @param Package $package |
||
43 | * |
||
44 | * @return void |
||
45 | */ |
||
46 | 3 | public function craft(Package $package) |
|
80 | |||
81 | /** |
||
82 | * Detect if a file is the config file. |
||
83 | * |
||
84 | * @param $file |
||
85 | * |
||
86 | * @return bool |
||
87 | */ |
||
88 | 3 | private function isConfigFile($file) |
|
92 | |||
93 | /** |
||
94 | * Detect if a file is the service provider file. |
||
95 | * |
||
96 | * @param $file |
||
97 | * |
||
98 | * @return bool |
||
99 | */ |
||
100 | 3 | private function isServiceProviderFile($file) |
|
104 | } |
||
105 |