Property | Type | Description | |
---|---|---|---|
$basePath | string | Base path URI | |
$controller | Current controller object | ||
$controllerClass | string | Current controller class name string | |
$controllers | array | Array of available controllers class names | |
$project | Project object | ||
$request | Pop\Http\Request | Request object |
Method | Description | |
---|---|---|
__construct ( array $controllers, Pop\Http\Request $request = null ) : |
Constructor | |
addControllers ( array $controller ) : |
Add controllers | |
controller ( ) : |
Get the current controller object (shorthand alias) | |
factory ( array $controllers, Pop\Http\Request $request = null ) : |
Create a Pop\Mvc\Router object | |
getAction ( ) : string | Get action from request within the current controller | |
getController ( ) : |
Get the current controller object | |
getControllerClass ( ) : string | Get the current controller class name string | |
getControllerName ( string $controller ) : string | Get a controller class name string, if available | |
getControllers ( ) : array | Get array of controller class names | |
getProject ( ) : |
Get the project object | |
getRequest ( ) : Pop\Http\Request | Get the request object | |
project ( ) : |
Get the project object (shorthand alias) | |
request ( ) : Pop\Http\Request | Get the request object (shorthand alias) | |
route ( |
Route to the correct controller |
Method | Description | |
---|---|---|
traverseControllers ( array $controllers, integer $depth ) : string | Traverse the controllers based on the path |
public __construct ( array $controllers, Pop\Http\Request $request = null ) : |
||
$controllers | array | |
$request | Pop\Http\Request | |
return |
public addControllers ( array $controller ) : |
||
$controller | array | |
return |
public controller ( ) : |
||
return |
public getController ( ) : |
||
return |
public getControllerClass ( ) : string | ||
return | string |
public getControllerName ( string $controller ) : string | ||
$controller | string | |
return | string |
public getControllers ( ) : array | ||
return | array |
public getProject ( ) : |
||
return |
public getRequest ( ) : Pop\Http\Request | ||
return | Pop\Http\Request |
public project ( ) : |
||
return |
public request ( ) : Pop\Http\Request | ||
return | Pop\Http\Request |
protected Controller,Pop\Mvc $controller | ||
return |
protected string $controllerClass | ||
return | string |
protected array $controllers | ||
return | array |
protected Project,Pop\Project $project | ||
return |