Class jController

Description

class base for controllers

A controller is used to implement one or many actions, one method for each action.

  • abstract:

Located in /core/jController.class.php (line 31)


	
			
Direct descendents
Class Description
jControllerDaoCrud a base class for crud controllers
jControllerCmdLine a base class for controllers used in command line application
Variable Summary
Method Summary
jController __construct (jRequest $request)
boolean boolParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
float floatParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
jResponse getResponse (string $name, [boolean $useOriginal = false])
integer intParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
mixed param (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
array params ()
void processZone (string $name, [array $params = array ()])
Variables
array $pluginParams = array() (line 42)

parameters for plugins

this array should contains all parameters needed by installed plugins for each action, see the documentation of each plugins to know this parameters. keys : name of an action or * for parameters to all action values : array that contains all plugin parameters

  • access: public
jRequest $request (line 48)

the request object

  • access: protected
Methods
Constructor __construct (line 54)
jController __construct (jRequest $request)
  • jRequest $request: the current request object

Redefined in descendants as:
boolParam (line 118)

same as param(), but convert the value to a boolean value. If it isn't a numerical value, return null.

  • return: the request parameter value
  • access: protected
boolean boolParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
  • string $parName: the name of the request parameter
  • mixed $parDefaultValue: the default returned value if the parameter doesn't exists
  • boolean $useDefaultIfEmpty: true: says to return the default value the value is ""
floatParam (line 102)

same as param(), but convert the value to a float value. If it isn't a numerical value, return null.

  • return: the request parameter value
  • access: protected
float floatParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
  • string $parName: the name of the request parameter
  • mixed $parDefaultValue: the default returned value if the parameter doesn't exists
  • boolean $useDefaultIfEmpty: true: says to return the default value the value is ""
getResponse (line 139)

get a response object.

  • return: the response object
  • access: protected
jResponse getResponse (string $name, [boolean $useOriginal = false])
  • string $name: the name of the response type (ex: "html")
  • boolean $useOriginal: true:don't use the response object redefined by the application
intParam (line 86)

same as param(), but convert the value to an integer value. If it isn't a numerical value, return null.

  • return: the request parameter value
  • access: protected
integer intParam (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
  • string $parName: the name of the request parameter
  • mixed $parDefaultValue: the default returned value if the parameter doesn't exists
  • boolean $useDefaultIfEmpty: true: says to return the default value the value is ""
param (line 74)

Gets the value of a request parameter. If not defined, gets its default value.

  • return: the request parameter value
  • access: protected
mixed param (string $parName, [mixed $parDefaultValue = null], [boolean $useDefaultIfEmpty = false])
  • string $parName: the name of the request parameter
  • mixed $parDefaultValue: the default returned value if the parameter doesn't exists
  • boolean $useDefaultIfEmpty: true: says to return the default value if the parameter value is ""

Redefined in descendants as:
params (line 131)
  • return: all request parameters
  • access: protected
array params ()
processZone (line 63)

jZone::get alias

  • access: protected
void processZone (string $name, [array $params = array ()])
  • string $name: zone selector
  • array $params: associative array, parameters

Documentation generated on Wed, 07 Sep 2011 13:46:46 +0200 by phpDocumentor 1.4.3