PHP 클래스 PopulateShell, cakephp-db-migrations

This is a simple utility to populate the database with data for testing, demoing, and other purposes.
상속: extends AppShell
파일 보기 프로젝트 열기: joelmoss/cakephp-db-migrations

공개 프로퍼티들

프로퍼티 타입 설명
$_user_defined True if user has passed any fixture names as arguments
$background
$data Array of fixture data to write into table
$dataSource Default datasource
$foreground
$helpers Population Helpers object
$options
$styles Console color styles
$tables Array of database tables

공개 메소드들

메소드 설명
_colorize ( $text = '', $style = null )
_formatColumn ( $name, $value )
_fromDb ( $model )
_loadModels ( ) Overides Shell::_loadModels, and builds the $uses array with Models.
_parsePhp ( $file )
_renameFixturesDir ( ) For legacy apps that have a config/fixtures directory, this will rename that to the new config/data directory.
_startFixture ( $name, $data )
_supportsColors ( )
create ( ) Alias for generate method
err ( $str )
g ( ) Alias for generate method
gen ( ) Alias for generate method
generate ( ) Generates a fixture file for each database table.
help ( ) Help method
initialize ( )
main ( )
out ( $string = '', $newline = true )
startup ( ) Starts up the the Shell and defines some basics
welcome ( )

메소드 상세

_colorize() 공개 메소드

public _colorize ( $text = '', $style = null )

_formatColumn() 공개 메소드

public _formatColumn ( $name, $value )

_fromDb() 공개 메소드

public _fromDb ( $model )

_loadModels() 공개 메소드

Overides Shell::_loadModels, and builds the $uses array with Models.
public _loadModels ( )

_parsePhp() 공개 메소드

public _parsePhp ( $file )

_renameFixturesDir() 공개 메소드

For legacy apps that have a config/fixtures directory, this will rename that to the new config/data directory.
public _renameFixturesDir ( )

_startFixture() 공개 메소드

public _startFixture ( $name, $data )

_supportsColors() 공개 메소드

public _supportsColors ( )

create() 공개 메소드

Alias for generate method
public create ( )

err() 공개 메소드

public err ( $str )

g() 공개 메소드

Alias for generate method
public g ( )

gen() 공개 메소드

Alias for generate method
public gen ( )

generate() 공개 메소드

This has been taken from the generator shell which is now deprecated
public generate ( )

help() 공개 메소드

Help method
public help ( )

initialize() 공개 메소드

public initialize ( )

main() 공개 메소드

public main ( )

out() 공개 메소드

public out ( $string = '', $newline = true )

startup() 공개 메소드

Starts up the the Shell and defines some basics
public startup ( )

welcome() 공개 메소드

public welcome ( )

프로퍼티 상세

$_user_defined 공개적으로 프로퍼티

True if user has passed any fixture names as arguments
public $_user_defined

$background 공개적으로 프로퍼티

public $background

$data 공개적으로 프로퍼티

Array of fixture data to write into table
public $data

$dataSource 공개적으로 프로퍼티

Default datasource
public $dataSource

$foreground 공개적으로 프로퍼티

public $foreground

$helpers 공개적으로 프로퍼티

Population Helpers object
public $helpers

$options 공개적으로 프로퍼티

public $options

$styles 공개적으로 프로퍼티

Console color styles
public $styles

$tables 공개적으로 프로퍼티

Array of database tables
public $tables