| Total Complexity | 4 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | class DatabaseFacade extends AbstractFacade |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * Initialize Propel database connection |
||
| 16 | * |
||
| 17 | * @api |
||
| 18 | */ |
||
| 19 | 1 | public function initDatabase(): void |
|
| 20 | { |
||
| 21 | 1 | $this->getFactory()->createPropelProvider()->init(); |
|
| 22 | 1 | } |
|
| 23 | |||
| 24 | /**git tag |
||
| 25 | * Generate propel config from project config |
||
| 26 | * |
||
| 27 | * @api |
||
| 28 | */ |
||
| 29 | 1 | public function generateConfig(): void |
|
| 30 | { |
||
| 31 | 1 | $this->getFactory()->createConfigGenerator()->generate(); |
|
| 32 | 1 | } |
|
| 33 | |||
| 34 | /** |
||
| 35 | * Build all models |
||
| 36 | * |
||
| 37 | * @api |
||
| 38 | * |
||
| 39 | * @return array |
||
| 40 | */ |
||
| 41 | 1 | public function buildModel(): array |
|
| 42 | { |
||
| 43 | 1 | return $this->getFactory()->createBuildModel()->buildModel(); |
|
| 44 | } |
||
| 45 | |||
| 46 | /** |
||
| 47 | * Runs all migrations |
||
| 48 | * |
||
| 49 | * @api |
||
| 50 | * |
||
| 51 | * @return array |
||
| 52 | */ |
||
| 53 | 1 | public function migrate(): array |
|
| 59 | ); |
||
| 60 | } |
||
| 61 | } |
||
| 62 |