XCL Web Application Platform 2.5.0
The XoopsCube Legacy Project
Loading...
Searching...
No Matches
XCube_Controller Class Reference
Inheritance diagram for XCube_Controller:
Legacy_Controller

Public Member Functions

 prepare (&$root)
 
 executeCommon ()
 
 executeHeader ()
 
 execute ()
 
 executeView ()
 
 executeForward (string $url, int $time=0, string $message=null)
 
 executeRedirect (string $url, int $time=1, string $message=null)
 
 addActionFilter (&$filter)
 
 _setupFilterChain ()
 
 _setupEnvironment ()
 
 _setupDB ()
 
getDB ()
 
 _setupLanguage ()
 
 _setupTextFilter ()
 
 _setupConfig ()
 
 _setupSession ()
 
 _setupUser ()
 
 _processFilter ()
 
 _setupBlock ()
 
 _processBlock ()
 
 _processPreBlockFilter ()
 
 _processPostFilter ()
 
 _processPreload ( $path)
 
_createDelegateManager ()
 
_createServiceManager ()
 
_createPermissionManager ()
 
_createRoleManager ()
 
_createContext ()
 

Data Fields

 $mRoot
 
 $_mBlockChain = []
 
 $_mFilterChain = []
 
 $_mLoadedFilterNames = []
 
 $mDB
 
 $mLocale
 
 $mLanguage
 
 $mSetupUser = null
 
 $mExecute = null
 
 $mSetupTextFilter = null
 

Detailed Description

Definition at line 51 of file XCube_Controller.class.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( )

Definition at line 131 of file XCube_Controller.class.php.

Member Function Documentation

◆ _createContext()

& _createContext ( )

Creates the context object to initial the root object, and returns it.

Returns
XCube_HttpContext

Reimplemented in Legacy_Controller.

Definition at line 478 of file XCube_Controller.class.php.

◆ _createDelegateManager()

& _createDelegateManager ( )

Creates an instance of the delegate manager and returns it.

Returns
XCube_DelegateManager

Reimplemented in Legacy_Controller.

Definition at line 423 of file XCube_Controller.class.php.

◆ _createPermissionManager()

& _createPermissionManager ( )

Creates an instance of the permission manager and returns it. XCube_PermissionManager Object

Returns

Definition at line 446 of file XCube_Controller.class.php.

◆ _createRoleManager()

& _createRoleManager ( )

Creates an instance of the role manager and returns it. XCube_RoleManager

Returns
Object

Definition at line 462 of file XCube_Controller.class.php.

◆ _createServiceManager()

& _createServiceManager ( )

Creates an instance of the service manager and returns it.

Returns
XCube_ServiceManager

Reimplemented in Legacy_Controller.

Definition at line 434 of file XCube_Controller.class.php.

◆ _processBlock()

_processBlock ( )

!FIXME.

Reimplemented in Legacy_Controller.

Definition at line 356 of file XCube_Controller.class.php.

◆ _processFilter()

_processFilter ( )

Calls the preFilter() member function of action filters which have been loaded to the list of the controller.

@access protected

Definition at line 341 of file XCube_Controller.class.php.

◆ _processPostFilter()

_processPostFilter ( )

Calls the postFilter() member function of action filters which have been loaded to the list of the controller.

@access protected

Definition at line 387 of file XCube_Controller.class.php.

◆ _processPreBlockFilter()

_processPreBlockFilter ( )

Calls the preBlockFilter() member function of action filters which have been loaded to the list of the controller.

@access protected

Reimplemented in Legacy_Controller.

Definition at line 376 of file XCube_Controller.class.php.

◆ _processPreload()

_processPreload ( $path)

This is an utility member function for the sub-class controller. Load files with the rule from $path, and add the instance of the sub-class to the chain.

@access protected

Parameters
string$pathAbsolute path.

Definition at line 401 of file XCube_Controller.class.php.

◆ _setupBlock()

_setupBlock ( )

!FIXME.

Reimplemented in Legacy_Controller.

Definition at line 350 of file XCube_Controller.class.php.

◆ _setupConfig()

_setupConfig ( )

This member function is overridden. Loads site configuration information, and sets them as a member property.

Reimplemented in Legacy_Controller.

Definition at line 312 of file XCube_Controller.class.php.

◆ _setupDB()

_setupDB ( )

Creates the instance of the DataBase class, and sets it as a member property.

@access protected

Reimplemented in Legacy_Controller.

Definition at line 274 of file XCube_Controller.class.php.

◆ _setupEnvironment()

_setupEnvironment ( )

This member function is overridden. Set up the controller and the environment.

Reimplemented in Legacy_Controller.

Definition at line 266 of file XCube_Controller.class.php.

◆ _setupFilterChain()

_setupFilterChain ( )

Create filter chain. @access protected

Reimplemented in Legacy_Controller.

Definition at line 259 of file XCube_Controller.class.php.

◆ _setupLanguage()

_setupLanguage ( )

Creates the instance of Language Manager class, and sets it as a member property.

@access protected

Reimplemented in Legacy_Controller.

Definition at line 291 of file XCube_Controller.class.php.

◆ _setupSession()

_setupSession ( )

This member function is overridden. Set up the session manager, then start the session.

@access protected

Returns
void

Reimplemented in Legacy_Controller.

Definition at line 322 of file XCube_Controller.class.php.

◆ _setupTextFilter()

_setupTextFilter ( )

Creates the instance of Text Filter class, and sets it as a member property.

@access protected

Definition at line 301 of file XCube_Controller.class.php.

◆ _setupUser()

_setupUser ( )

Sets a main object to the root object. In other words, it restores the main object of the session or similar.

Reimplemented in Legacy_Controller.

Definition at line 332 of file XCube_Controller.class.php.

◆ addActionFilter()

addActionFilter ( & $filter)

Adds the ActionFilter instance.

Parameters
XCube_ActionFilter$filter

Definition at line 251 of file XCube_Controller.class.php.

◆ execute()

execute ( )

Executes the main logic.

@access public

Definition at line 210 of file XCube_Controller.class.php.

◆ executeCommon()

executeCommon ( )

This member function is the actual initialization process of the web application. Some Nuke-like bases might call this function at any time.

@access public

Reimplemented in Legacy_Controller.

Definition at line 166 of file XCube_Controller.class.php.

◆ executeForward()

executeForward ( string $url,
int $time = 0,
string $message = null )

TODO We may change this name to forward()

Parameters
string$urlCan't use html tags.
int$time
string | null$message

Definition at line 229 of file XCube_Controller.class.php.

◆ executeHeader()

executeHeader ( )

Usually this member function is called after executeCommon(). But, some bases don't call this. Therefore, the page controller type base does not have to write the necessary code here. For example, this is good to call blocks.

Reimplemented in Legacy_Controller.

Definition at line 200 of file XCube_Controller.class.php.

◆ executeRedirect()

executeRedirect ( string $url,
int $time = 1,
string $message = null )

Redirect to the specified URL with displaying message.

Parameters
string$urlCan't use html tags.
int$time
string | null$message

Definition at line 242 of file XCube_Controller.class.php.

◆ executeView()

executeView ( )

Executes the view logic. This member function is overridden.

@access public

Reimplemented in Legacy_Controller.

Definition at line 219 of file XCube_Controller.class.php.

◆ getDB()

& getDB ( )

Gets the DB instance.

@access public

Definition at line 282 of file XCube_Controller.class.php.

◆ prepare()

prepare ( & $root)

This member function is overridden. The subclass implements the initialization process that sets up the final root object.

Parameters
XCube_Root$root

Reimplemented in Legacy_Controller.

Definition at line 150 of file XCube_Controller.class.php.

Field Documentation

◆ $_mBlockChain

$_mBlockChain = []

Array of a procedure class object.

Definition at line 64 of file XCube_Controller.class.php.

◆ $_mFilterChain

$_mFilterChain = []

Vector Array of XCube_ActionFilter class object.

Remarks
typedef std:vector<XCube_ActionFilter*> FilterList;
FilterList _mFilterChain;

Definition at line 75 of file XCube_Controller.class.php.

◆ $_mLoadedFilterNames

$_mLoadedFilterNames = []

This is Map-Array to keep names of action filter classes which are applied as filters.

Definition at line 82 of file XCube_Controller.class.php.

◆ $mDB

$mDB

Definition at line 89 of file XCube_Controller.class.php.

◆ $mExecute

$mExecute = null

Definition at line 121 of file XCube_Controller.class.php.

◆ $mLanguage

$mLanguage

Definition at line 105 of file XCube_Controller.class.php.

◆ $mLocale

$mLocale

Definition at line 97 of file XCube_Controller.class.php.

◆ $mRoot

$mRoot

Definition at line 57 of file XCube_Controller.class.php.

◆ $mSetupTextFilter

$mSetupTextFilter = null

Definition at line 129 of file XCube_Controller.class.php.

◆ $mSetupUser

$mSetupUser = null

Definition at line 113 of file XCube_Controller.class.php.


The documentation for this class was generated from the following file: