1 | <?php |
||
18 | abstract class AbstractGenerator implements GeneratorInterface |
||
19 | { |
||
20 | /** @var \Net\Bazzline\Component\Locator\Configuration\Configuration */ |
||
21 | protected $configuration; |
||
22 | |||
23 | /** @var FileExistsStrategyInterface */ |
||
24 | protected $fileExistsStrategy; |
||
25 | |||
26 | /** |
||
27 | * @param \Net\Bazzline\Component\Locator\Configuration\Configuration $configuration |
||
28 | * @return $this |
||
29 | */ |
||
30 | public function setConfiguration(Configuration $configuration) |
||
36 | |||
37 | /** |
||
38 | * @param FileExistsStrategyInterface $strategy |
||
39 | * @return $this |
||
40 | */ |
||
41 | public function setFileExistsStrategy(FileExistsStrategyInterface $strategy) |
||
47 | |||
48 | /** |
||
49 | * @param string $filePath |
||
50 | * @param string $fileName |
||
51 | * @throws RuntimeException |
||
52 | */ |
||
53 | protected function moveOldFileIfExists($filePath, $fileName) |
||
70 | |||
71 | /** |
||
72 | * @param string $fullQualifiedFileName |
||
73 | * @param string $content |
||
74 | * @throws RuntimeException |
||
75 | */ |
||
76 | protected function dumpToFile($fullQualifiedFileName, $content) |
||
84 | |||
85 | /** |
||
86 | * @return string |
||
87 | */ |
||
88 | protected function getAuthorString() |
||
92 | } |