App
in package
App class is used for encapsulate common parts of code for the normal App execution.
Tags
Table of Contents
- $dataBase : DataBase
- Database access manager.
- $request : Request
- Gives us access to the HTTP request parameters.
- $response : Response
- HTTP response object.
- $uri : string
- Requested Uri
- __construct() : mixed
- Initializes the app.
- close() : mixed
- Save log and disconnects from the database.
- connect() : bool
- Connects to the database and loads the configuration.
- render() : mixed
- Returns the data into the standard output.
- run() : bool
- Runs the application core.
- die() : mixed
- getUriParam() : string
- Returns param number $num in uri.
- ipWarning() : mixed
- Add or increase the attempt counter of the current client IP address.
- isIPBanned() : bool
- Returns true if the client IP has been banned.
- loadPlugins() : mixed
- Initialize plugins.
Properties
$dataBase
Database access manager.
protected
DataBase
$dataBase
$request
Gives us access to the HTTP request parameters.
protected
Request
$request
$response
HTTP response object.
protected
Response
$response
$uri
Requested Uri
protected
string
$uri
Methods
__construct()
Initializes the app.
public
__construct([string $uri = '/' ]) : mixed
Parameters
- $uri : string = '/'
Return values
mixed —close()
Save log and disconnects from the database.
public
close() : mixed
Return values
mixed —connect()
Connects to the database and loads the configuration.
public
connect() : bool
Return values
bool —render()
Returns the data into the standard output.
public
render() : mixed
Return values
mixed —run()
Runs the application core.
public
run() : bool
Return values
bool —die()
protected
abstract die(int $status[, string $message = '' ]) : mixed
Parameters
- $status : int
- $message : string = ''
Return values
mixed —getUriParam()
Returns param number $num in uri.
protected
getUriParam(string $num) : string
Parameters
- $num : string
Return values
string —ipWarning()
Add or increase the attempt counter of the current client IP address.
protected
ipWarning() : mixed
Return values
mixed —isIPBanned()
Returns true if the client IP has been banned.
protected
isIPBanned() : bool
Return values
bool —loadPlugins()
Initialize plugins.
private
loadPlugins() : mixed