PHP Class Pix_Controller, pixframework

显示文件 Open project: pixnet/pixframework Class Usage Examples

Public Properties

Property Type Description
$view

Protected Properties

Property Type Description
$_dispatchers
$_helper_manager Pix_Helper_Manager
$actionName
$controllerName

Public Methods

Method Description
__call ( $func, $args )
__construct ( )
addCommonHelpers ( ) : void addCommonHelpers add common helper
addDispatcher ( Pix_Controller_Dispatcher | callable $dispatcher ) : void addDispatcher add new Dispatcher
addHelper ( string $helper, array $methods = null, array $options = [] ) : void addHelper add static helper in Pix_Controller
dispatch ( string $data_path ) : void dispatch dispatch the request action
draw ( string $filename ) : string draw draw a partial file
getActionName ( ) : string getActionName get Action name
getControllerName ( ) : string getControllerName get Controller name
getHelperManager ( ) : Pix_Helper_Manager getHelperManager get Helper Manager
getURI ( ) : string getURI get request URI
init ( )
noview ( ) : void noview finish action without drawing view
redirect ( string $url, integer $code = 302 ) : void redirect finish action and redirect to $url
redraw ( string $partial_name ) : void redraw finish action and draw another partial $partial_name
setView ( Pix_Partial $v ) : void setView set Controller view

Method Details

__call() public method

public __call ( $func, $args )

__construct() public method

public __construct ( )

addCommonHelpers() public static method

addCommonHelpers add common helper
public static addCommonHelpers ( ) : void
return void

addDispatcher() public static method

addDispatcher add new Dispatcher
public static addDispatcher ( Pix_Controller_Dispatcher | callable $dispatcher ) : void
$dispatcher Pix_Controller_Dispatcher | callable
return void

addHelper() public static method

addHelper add static helper in Pix_Controller
public static addHelper ( string $helper, array $methods = null, array $options = [] ) : void
$helper string Helper name
$methods array
$options array
return void

dispatch() public static method

dispatch dispatch the request action
public static dispatch ( string $data_path ) : void
$data_path string
return void

draw() public method

draw draw a partial file
public draw ( string $filename ) : string
$filename string
return string output

getActionName() public method

getActionName get Action name
public getActionName ( ) : string
return string

getControllerName() public method

getControllerName get Controller name
public getControllerName ( ) : string
return string

getHelperManager() public static method

getHelperManager get Helper Manager
public static getHelperManager ( ) : Pix_Helper_Manager
return Pix_Helper_Manager

getURI() public method

getURI get request URI
public getURI ( ) : string
return string

init() public method

public init ( )

noview() public method

noview finish action without drawing view
public noview ( ) : void
return void

redirect() public method

redirect finish action and redirect to $url
public redirect ( string $url, integer $code = 302 ) : void
$url string
$code integer
return void

redraw() public method

redraw finish action and draw another partial $partial_name
public redraw ( string $partial_name ) : void
$partial_name string
return void

setView() public method

setView set Controller view
public setView ( Pix_Partial $v ) : void
$v Pix_Partial
return void

Property Details

$_dispatchers protected_oe static_oe property

protected static $_dispatchers

$_helper_manager protected_oe static_oe property

Pix_Helper_Manager
protected static $_helper_manager

$actionName protected_oe property

protected $actionName

$controllerName protected_oe property

protected $controllerName

$view public_oe property

public $view