Context __construct(
[
&$vars = NULL], array
$vars
)
|
|
Constructor
Parameters:
|
array |
$vars: |
Simple associative array used to initialize private $vars. |
|
|
&$vars: |
|
Information Tags:
Redefined in descendants as:
void add_var(
string
$name,
&$value, any
$value
)
|
|
Adds new variable.
Parameters:
|
string |
$name: |
|
|
any |
$value: |
|
|
|
&$value: |
|
API Tags:
any &get_var(
string
$name
)
|
|
Gets variable as reference. Use this function if you intend to change the value.
Parameters:
API Tags:
Information Tags:
| Throws: | TE_Var_Not_Exists |
any query_var(
string
$name
)
|
|
Query variable. Similar to get_var() but returns copy of the variable, not reference. Use this function instead of get_var() if you are not intending to change the value.
Parameters:
API Tags:
void set_var(
string
$name, any
$value
)
|
|
Sets variable.
Throws exception if variable with name provided with $name does not exists.
Parameters:
|
string |
$name: |
|
|
any |
$value: |
|
API Tags:
Information Tags:
| Throws: | TE_Var_Not_Exists |
boolean vars_exists(
string
$key
)
|
|
Checks if var exists (it is already set)
Parameters:
API Tags:
void _set_var(
string
$name,
&$value, any
$value
)
|
|
Actual set of the variable
Parameters:
|
string |
$name: |
|
|
any |
$value: |
|
|
|
&$value: |
|
API Tags: