Documentation

MigrationController extends AbstractController
in package

Console database controller class

Tags
category

Pop\Kettle

author

Nick Sagona, III nick@nolainteractive.com

copyright

Copyright (c) 2012-2023 NOLA Interactive, LLC. (http://www.nolainteractive.com)

license

http://www.popphp.org/license New BSD License

version
1.6.2

Table of Contents

$application  : Application
Application object
$console  : Console
Console object
$defaultAction  : string
Default action
__construct()  : mixed
Constructor for the controller
application()  : Application
Get application object
console()  : Console
Get request object
create()  : void
Create command
dispatch()  : void
Dispatch the controller based on the action
error()  : void
Default error action method
getDefaultAction()  : string
Get the default action
reset()  : void
Reset command
rollback()  : void
Rollback command
run()  : void
Run command
setDefaultAction()  : AbstractController
Set the default action

Properties

Methods

create()

Create command

public create(string $class[, string $database = 'default' ]) : void
Parameters
$class : string
$database : string = 'default'
Return values
void

dispatch()

Dispatch the controller based on the action

public dispatch([string $action = null ][, array<string|int, mixed> $params = null ]) : void
Parameters
$action : string = null
$params : array<string|int, mixed> = null
Tags
throws
Exception
Return values
void

getDefaultAction()

Get the default action

public getDefaultAction() : string
Return values
string

reset()

Reset command

public reset([string $database = 'default' ]) : void
Parameters
$database : string = 'default'
Return values
void

rollback()

Rollback command

public rollback([int $steps = 1 ][, string $database = 'default' ]) : void
Parameters
$steps : int = 1
$database : string = 'default'
Return values
void

run()

Run command

public run([int $steps = 1 ][, string $database = 'default' ]) : void
Parameters
$steps : int = 1
$database : string = 'default'
Return values
void

Search results