|
static | get_instance_for_cache (cache_definition $definition) |
| Returns an instance of the data source class that the cache can use for loading data using the other methods specified by this interface.
|
|
|
static elements | $instance = null |
| the singleton instance of this class.
|
|
◆ get_instance_for_cache()
static mod_scorm\cache\elements::get_instance_for_cache |
( |
cache_definition | $definition | ) |
|
|
static |
Returns an instance of the data source class that the cache can use for loading data using the other methods specified by this interface.
- Parameters
-
- Return values
-
Implements cache_data_source.
◆ load_for_cache()
mod_scorm\cache\elements::load_for_cache |
( |
| $key | ) |
|
Loads the data for the key provided ready formatted for caching.
- Parameters
-
string | int | $key | The key to load. |
- Return values
-
string | What ever data should be returned, or null if it can't be loaded. |
- Exceptions
-
Implements cache_data_source.
◆ load_many_for_cache()
mod_scorm\cache\elements::load_many_for_cache |
( |
array | $keys | ) |
|
Loads several keys for the cache.
- Parameters
-
array | $keys | An array of keys each of which will be string|int. |
- Return values
-
array | An array of matching data items. |
Implements cache_data_source.
The documentation for this class was generated from the following file:
- mod/scorm/classes/cache/elements.php