File tree Expand file tree Collapse file tree 1 file changed +48
-0
lines changed
Expand file tree Collapse file tree 1 file changed +48
-0
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+
3+ /**
4+ * @author Mohammed Moussaoui
5+ * @copyright Copyright (c) Mohammed Moussaoui. All rights reserved.
6+ * @license MIT License. For full license information see LICENSE file in the project root.
7+ * @link https://github.com/DevNet-Framework
8+ */
9+
10+ namespace DevNet \Cli \Templating ;
11+
12+ class CodeGeneratorProvider implements ICodeGeneratorProvider
13+ {
14+ protected string $ name ;
15+ protected string $ description ;
16+ protected ICodeGenerator $ generator ;
17+
18+ public function __construct (string $ name , string $ description , ICodeGenerator $ generator )
19+ {
20+ $ this ->name = $ name ;
21+ $ this ->description = $ description ;
22+ $ this ->generator = $ generator ;
23+ }
24+
25+ /**
26+ * Get the generator name
27+ */
28+ public function getName (): string
29+ {
30+ return $ this ->name ;
31+ }
32+
33+ /**
34+ * Get the generator description
35+ */
36+ public function getDescription (): string
37+ {
38+ return $ this ->description ;
39+ }
40+
41+ /**
42+ * Get the code generator
43+ */
44+ public function getGenerator (): ICodeGenerator
45+ {
46+ return $ this ->generator ;
47+ }
48+ }
You can’t perform that action at this time.
0 commit comments