Skip to content

Commit f57330d

Browse files
committed
More about code generators
1 parent c6e2b0c commit f57330d

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

README.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Install via Composer:
1313
```json
1414
{
1515
"require": {
16-
"gossi/php-code-generator": "~1"
16+
"gossi/php-code-generator": "dev-master"
1717
}
1818
}
1919
```
@@ -70,10 +70,15 @@ $code = $generator->generate($class);
7070

7171
### Code Generators
7272

73+
The package ships with two generators, which are configurable with an associative array as constructor parameter. Alternatively if you have a project that uses the same configuration over and over again, extend the respective config object and pass it instead of the configuration array.
74+
7375
**CodeGenerator**
7476

7577
Creates code for a given model
7678

79+
Config: `gossi\codegen\config\CodeGeneratorConfig` <br>
80+
Options:
81+
7782
| Key | Type | Default Value | Description |
7883
| --- | ---- | ------------- | ----------- |
7984
| generateDocblock | boolean | true | enables docblock generation prior to code generation |
@@ -83,7 +88,8 @@ Creates code for a given model
8388

8489
Creates a complete php file with the given model inside.
8590

86-
Same options as `CodeGenerator` plus:
91+
Config: `gossi\codegen\config\CodeFileGeneratorConfig` <br>
92+
Options: Same options as `CodeGenerator` plus:
8793

8894
| Key | Type | Default Value | Description |
8995
| --- | ---- | ------------- | ----------- |

0 commit comments

Comments
 (0)