ILIAS
release_4-3 Revision
|
Session based immediate storage. More...
Public Member Functions | |
__construct ($a_component_id, $a_sess_id="") | |
Constructor. | |
set ($a_key, $a_val) | |
Set a value. | |
get ($a_key) | |
Get a value for a key. | |
destroySession ($a_session_id) | |
Destroy session(s). |
Protected Attributes | |
$session_id = "" | |
$component_id = "" |
Static Protected Attributes | |
static | $values = array() |
Session based immediate storage.
This class stores session based user data in the database. The difference to ilSession is that data is written immediately when the set() function is called and that this data is written "per key".
Please note that the values are limited to TEXT(1000)!
This class is needed for cases, where ajax calls should write session based data.
Since more concurrent ajax calls can be initiated by a page request, these calls may run into race conditions, if ilSession is used, since it always reads all key/value pairs at the beginning of a request and writes all of them at the end. Similar issues can appear if a page initiates additional requests by (i)frames.
Definition at line 27 of file class.ilSessionIStorage.php.
ilSessionIStorage::__construct | ( | $a_component_id, | |
$a_sess_id = "" |
|||
) |
Constructor.
string | $a_component_id | component id (e.g. "crs", "lm", ...) |
string | $a_sess_id | session id |
Definition at line 39 of file class.ilSessionIStorage.php.
ilSessionIStorage::destroySession | ( | $a_session_id | ) |
Destroy session(s).
This is called by ilSession->destroy
@return |
Definition at line 108 of file class.ilSessionIStorage.php.
Referenced by ilSession\_destroy().
ilSessionIStorage::get | ( | $a_key | ) |
Get a value for a key.
Definition at line 81 of file class.ilSessionIStorage.php.
References $component_id.
ilSessionIStorage::set | ( | $a_key, | |
$a_val | |||
) |
Set a value.
string | $a_val | value |
Definition at line 57 of file class.ilSessionIStorage.php.
References $component_id.
|
protected |
Definition at line 30 of file class.ilSessionIStorage.php.
|
protected |
Definition at line 29 of file class.ilSessionIStorage.php.
|
staticprotected |
Definition at line 31 of file class.ilSessionIStorage.php.