Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.10.x will end 8 November 2021 (12 months).
  • Bug fixes for security issues in 3.10.x will end 9 May 2022 (18 months).
  • PHP version: minimum PHP 7.2.0 Note: minimum PHP version has increased since Moodle 3.8. PHP 7.3.x and 7.4.x are supported too.

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

Search area base class for messages.

Copyright: 2016 Devang Gaur
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 219 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: base_message  - X-Ref

Search area base class for messages.

get_document($record, $options = array()   X-Ref
Returns the document associated with this message record.

param: stdClass $record
param: array    $options
return: \core_search\document

get_doc_url(\core_search\document $doc)   X-Ref
Link to the message.

param: \core_search\document $doc
return: \moodle_url

get_context_url(\core_search\document $doc)   X-Ref
Link to the conversation.

param: \core_search\document $doc
return: \moodle_url

get_current_other_users($doc)   X-Ref
Sorting the current(user1) and other(user2) user in the conversation.

param: \core_search\document $doc
return: array()

get_document_recordset_helper($modifiedfrom, \context $context = null,$userfield)   X-Ref
Helper function to implement get_document_recordset for subclasses.

param: int $modifiedfrom Modified from date
param: \context|null $context Context or null
param: string $userfield Name of user field (from or to) being considered
return: \moodle_recordset|null Recordset or null if no results possible

get_doc_icon(\core_search\document $doc)   X-Ref
Returns an icon instance for the document.

param: \core_search\document $doc
return: \core_search\document_icon

get_category_names()   X-Ref
Returns a list of category names associated with the area.

return: array