Class Socialveo\Tasks\GenerateModelTask

InheritanceSocialveo\Tasks\GenerateModelTask » Phalcon\CLI\Task

Class GenerateModelTask

Public Methods

Hide inherited methods

MethodDescriptionDefined By
exportVar() Exports var with php code and inserts the tabs Socialveo\Tasks\GenerateModelTask
formatCode() Format code Socialveo\Tasks\GenerateModelTask
mainAction() Generate model from database schema Socialveo\Tasks\GenerateModelTask
tableAction() Generate model from database schema Socialveo\Tasks\GenerateModelTask

Protected Methods

Hide inherited methods

MethodDescriptionDefined By
generateFromTable() Generate model from table Socialveo\Tasks\GenerateModelTask
generateModel() Generate model class Socialveo\Tasks\GenerateModelTask
parseTable() Parse table definitions Socialveo\Tasks\GenerateModelTask

Method Details

exportVar() public method

Exports var with php code and inserts the tabs

public string exportVar ( $var, $insert_tabs 0, $tab_string '    ' )
$var mixed
$insert_tabs integer
$tab_string string
formatCode() public method

Format code

public string formatCode ( $var, $insert_tabs 0, $tab_string '    ', $validate true )
$var array|string
$insert_tabs integer
$tab_string string
$validate mixed
generateFromTable() protected method

Generate model from table

protected void generateFromTable ( $table, $options )
$table string
$options array
generateModel() protected method

Generate model class

protected string generateModel ( $migration, $table, $modelName, $package )
$migration Socialveo\Core\library\db\Migration
$table string
$modelName string
$package string
mainAction() public method

Generate model from database schema

public void mainAction ( $options = [] )
$options array
parseTable() protected method

Parse table definitions

protected array parseTable ( $migration, $table )
$migration Socialveo\Core\library\db\Migration
$table string
tableAction() public method

Generate model from database schema

public void tableAction ( $options = [] )
$options array