Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

(no description)

File Size: 84 lines (3 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

cache_phpunit_dummy_datasource_versionable:: (4 methods):
  get_instance_for_cache()
  get_last_instance()
  has_value()
  load_for_cache_versioned()


Class: cache_phpunit_dummy_datasource_versionable  - X-Ref

A dummy datasource which supports versioning.

get_instance_for_cache(cache_definition $definition)   X-Ref
Returns an instance of this object for use with the cache.

return: cache_phpunit_dummy_datasource New object
param: cache_definition $definition

get_last_instance()   X-Ref
Gets the last instance that was created.

return: cache_phpunit_dummy_datasource_versionable

has_value(string $key, int $version, $data)   X-Ref
Sets up the datasource so that it has a value for a particular key.

param: string $key Key
param: int $version Version for key
param: mixed $data

load_for_cache_versioned($key, int $requiredversion, &$actualversion)   X-Ref
Loads versioned data.

return: mixed Data retrieved from cache or false if none
param: int|string $key Key
param: int $requiredversion Minimum version number
param: mixed $actualversion Should be set to the actual version number retrieved