View
in package
Abstract class View Instanciate a view
Tags
Table of Contents
- $access_level : int
- $container : Container
- $request : Request
- __construct() : mixed
- View constructor
- encode() : string
- JSON Encoding method
- render() : string
- Render the page
- edit() : mixed
- requestAuth() : string
- Display the general auth page
- show() : mixed
Properties
$access_level
protected
int
$access_level
depends on the users permissions
$container
protected
Container
$container
$request
protected
Request
$request
Methods
__construct()
View constructor
public
__construct(Container $c[, Request|null $request = null ]) : mixed
Parameters
- $c : Container
- $request : Request|null = null
Return values
mixed —encode()
JSON Encoding method
public
abstract encode(int $access_level) : string
Parameters
- $access_level : int
-
depends on the user's privileges
Return values
string —json encoded string of the object
render()
Render the page
public
render(int $method[, int $access_level = Renderer::OTHER_MODE ]) : string
Parameters
- $method : int
-
method to render
- $access_level : int = Renderer::OTHER_MODE
-
access level of the user
Tags
Return values
string —html code
edit()
protected
abstract edit() : mixed
Return values
mixed —requestAuth()
Display the general auth page
protected
requestAuth(Model $model) : string
Parameters
- $model : Model
-
associated model (list, item or user)
Tags
Return values
string —html code
show()
protected
abstract show() : mixed