Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.2.x will end 22 April 2024 (12 months).
  • Bug fixes for security issues in 4.2.x will end 7 October 2024 (18 months).
  • PHP version: minimum PHP 8.0.0 Note: minimum PHP version has increased since Moodle 4.1. PHP 8.1.x is supported too.

Differences Between: [Versions 310 and 402] [Versions 311 and 402] [Versions 39 and 402] [Versions 400 and 402] [Versions 401 and 402]

Log store manager.

Copyright: 2013 Petr Skoda {@link http://skodak.org}
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 202 lines (7 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

manager:: (7 methods):
  init()
  process()
  get_readers()
  get_supported_reports()
  get_supported_logstores()
  get_store_plugins()
  dispose()


Class: manager  - X-Ref

init()   X-Ref
Delayed initialisation of singleton.


process(\core\event\base $event)   X-Ref
Called from the observer only.

param: \core\event\base $event

get_readers($interface = null)   X-Ref
Returns list of available log readers.

This way the reports find out available sources of data.

param: string $interface Returned stores must implement this interface.
return: \core\log\reader[] list of available log data readers

get_supported_reports($logstore)   X-Ref
Get a list of reports that support the given store instance.

param: string $logstore Name of the store.
return: array List of supported reports

get_supported_logstores($component)   X-Ref
For a given report, returns a list of log stores that are supported.

param: string $component component.
return: false|array list of logstores that support the given report. It returns false if the given $component doesn't

get_store_plugins()   X-Ref
Intended for store management, do not use from reports.

return: store[] Returns list of available store plugins.

dispose()   X-Ref
Usually called automatically from shutdown manager,
this allows us to implement buffering of write operations.