Download the PHP package ekhaled/f3-cortex-model-generator without Composer
On this page you can find all versions of the php package ekhaled/f3-cortex-model-generator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download ekhaled/f3-cortex-model-generator
More information about ekhaled/f3-cortex-model-generator
Files in ekhaled/f3-cortex-model-generator
Download ekhaled/f3-cortex-model-generator
More information about ekhaled/f3-cortex-model-generator
Files in ekhaled/f3-cortex-model-generator
Vendor ekhaled
Package f3-cortex-model-generator
Short Description Generates F3 Cortex models by reverse engineering existing database schema
License MIT
Homepage https://github.com/ekhaled/schema-parser-mysql
Package f3-cortex-model-generator
Short Description Generates F3 Cortex models by reverse engineering existing database schema
License MIT
Homepage https://github.com/ekhaled/schema-parser-mysql
Please rate this library. Is it a good library?
Informations about the package f3-cortex-model-generator
F3 Cortex model generator
Generates F3 Cortex models by reverse engineering existing database schema.
Currently only supports MySQL.
Installation
Please add
to your composer file.
Usage
Create an executable PHP file with the following contents
and, just run the file from the command line.
Options
output
- specifies the folder where models will be output to.DB
- an array in the following format ['host' => 'host.com', 'username' => '', 'password' => '', 'dbname' => 'name_of_database',]namespace
- Namespace of the generated modelsextends
- if you have a base model, you can make the generated model extend that model by specifying it here.relationNamespace
- Namespace of the connected classes that constitute relationships with a given model, usually it's the same asnamespace
template
- Path to file containing a custom template, if not specified a built-in template will be used.indentation
- an array that indicates what type of unit of indentation to be used on template generation followed by a starting level.
For example:['unit' => ' ', 'start_level' => 3]
. This will use 2 spaces as indentation starting at 6 spaces.
This is applied to the array defined by the {{FIELDCONF}} templateexclude_views
- Whether to generate models for Views too, defaults to false.exclude_connectors
- Whether to generate stub models for many-to-many connector tables, defaults to false. (Sometimes you might need these models to create db tables, for example for automated tests in test databases).exclude
- An array containing all tables that you would like to exclude while generating models. For example:array('migrations')
.
Custom templates
A typical custom template would look like:
Just ensure that the placeholders are in place, and they will get replaced during model generation.
Supported placeholders are:
{{NAMESPACE}}
{{CLASSNAME}}
{{EXTENDS}}
{{FIELDCONF}}
{{TABLENAME}}
All versions of f3-cortex-model-generator with dependencies
PHP Build Version
Package Version
The package ekhaled/f3-cortex-model-generator contains the following files
Loading the files please wait ....