Moodle  2.2.1
http://www.collinsharper.com
HTMLPurifier_Context Class Reference

Public Member Functions

 register ($name, &$ref)
get ($name, $ignore_error=false)
 destroy ($name)
 exists ($name)
 loadArray ($context_array)

Detailed Description

Registry object that contains information about the current context.

Warning:
Is a bit buggy when variables are set to null: it thinks they don't exist! So use false instead, please.
Note:
Since the variables Context deals with may not be objects, references are very important here! Do not remove!

Definition at line 10 of file Context.php.


Member Function Documentation

destroy ( name)

Destorys a variable in the context.

Parameters:
$nameString name

Definition at line 53 of file Context.php.

exists ( name)

Checks whether or not the variable exists.

Parameters:
$nameString name

Definition at line 66 of file Context.php.

& get ( name,
ignore_error = false 
)

Retrieves a variable reference from the context.

Parameters:
$nameString name
$ignore_errorBoolean whether or not to ignore error

Definition at line 37 of file Context.php.

loadArray ( context_array)

Loads a series of variables from an associative array

Parameters:
$context_arrayAssoc array of variables to load

Definition at line 74 of file Context.php.

register ( name,
&$  ref 
)

Registers a variable into the context.

Parameters:
$nameString name
$refReference to variable to be registered

Definition at line 23 of file Context.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations