ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
|
Public Member Functions | |
getTableVersion ($name) | |
Get table version. More... | |
setTableVersion ($name, $version) | |
Set table version. More... | |
insertOrUpdate ($table, array $keys, array $data) | |
Insert or update a key-value in the store. More... | |
get ($type, $key) | |
Retrieve a value from the data store. More... | |
set ($type, $key, $value, $expire=null) | |
Save a value in the data store. More... | |
delete ($type, $key) | |
Delete an entry from the data store. More... | |
Public Member Functions inherited from SimpleSAML\Store | |
get ($type, $key) | |
Retrieve a value from the data store. More... | |
set ($type, $key, $value, $expire=null) | |
Save a value to the data store. More... | |
delete ($type, $key) | |
Delete a value from the data store. More... | |
Data Fields | |
$pdo | |
$driver | |
$prefix | |
Protected Member Functions | |
__construct () | |
Initialize the SQL data store. More... | |
Private Member Functions | |
initTableVersionTable () | |
Initialize the table-version table. More... | |
initKVTable () | |
Initialize key-value table. More... | |
cleanKVStore () | |
Clean the key-value table of expired entries. More... | |
Private Attributes | |
$tableVersions | |
Additional Inherited Members | |
Static Public Member Functions inherited from SimpleSAML\Store | |
static | getInstance () |
Retrieve our singleton instance. More... | |
|
protected |
Initialize the SQL data store.
Definition at line 51 of file SQL.php.
References $config, $password, SimpleSAML\Store\SQL\initKVTable(), and SimpleSAML\Store\SQL\initTableVersionTable().
|
private |
Clean the key-value table of expired entries.
Definition at line 230 of file SQL.php.
References $params, $query, array, and SimpleSAML\Logger\debug().
Referenced by SimpleSAML\Store\SQL\set().
SimpleSAML\Store\SQL::delete | ( | $type, | |
$key | |||
) |
SimpleSAML\Store\SQL::get | ( | $type, | |
$key | |||
) |
SimpleSAML\Store\SQL::getTableVersion | ( | $name | ) |
Get table version.
string | $name | Table name. |
Definition at line 131 of file SQL.php.
References $name.
Referenced by SimpleSAML\Store\SQL\initKVTable().
|
private |
Initialize key-value table.
Definition at line 100 of file SQL.php.
References $query, SimpleSAML\Store\SQL\getTableVersion(), and SimpleSAML\Store\SQL\setTableVersion().
Referenced by SimpleSAML\Store\SQL\__construct().
|
private |
Initialize the table-version table.
Definition at line 77 of file SQL.php.
Referenced by SimpleSAML\Store\SQL\__construct().
Insert or update a key-value in the store.
Since various databases implement different methods for doing this, we abstract it away here.
string | $table | The table we should update. |
array | $keys | The key columns. |
array | $data | Associative array with columns. |
Definition at line 172 of file SQL.php.
References $query, array, SimpleSAML\Logger\error(), and string.
Referenced by SimpleSAML\Store\SQL\set(), and SimpleSAML\Store\SQL\setTableVersion().
SimpleSAML\Store\SQL::set | ( | $type, | |
$key, | |||
$value, | |||
$expire = null |
|||
) |
Save a value in the data store.
string | $type | The type of the data. |
string | $key | The key to insert. |
mixed | $value | The value itself. |
int | null | $expire | The expiration time (unix timestamp), or null if it never expires. |
Definition at line 293 of file SQL.php.
References $data, $type, array, SimpleSAML\Store\SQL\cleanKVStore(), and SimpleSAML\Store\SQL\insertOrUpdate().
SimpleSAML\Store\SQL::setTableVersion | ( | $name, | |
$version | |||
) |
Set table version.
string | $name | Table name. |
int | $version | Table version. |
Definition at line 149 of file SQL.php.
References $name, $version, array, and SimpleSAML\Store\SQL\insertOrUpdate().
Referenced by SimpleSAML\Store\SQL\initKVTable().