| [ Index ] |
PHP Cross Reference of Moodle 1.9.3 [Build 15-Oct-2008] |
[Source view] [Print] [Project Stats]
Global Search Engine for Moodle
| Author: | Valery Fremaux [valery.fremaux@club-internet.fr] > 1.8 |
| License: | http://www.gnu.org/copyleft/gpl.html GNU Public License |
| File Size: | 301 lines (12 kb) |
| Included or required: | 0 times |
| Referenced: | 0 times |
| Includes or requires: | 0 files |
ChatTrackSearchDocument:: (10 methods):
__construct()
chat_make_link()
chat_get_session_tracks()
chat_iterator()
chat_get_content_for_index()
chat_single_document()
chat_delete()
chat_db_names()
chat_check_text_access()
chat_link_post_processing()
Class: ChatTrackSearchDocument - X-Ref
a class for representing searchable information| __construct(&$chatsession, $chat_module_id, $course_id, $group_id, $context_id) X-Ref |
| constructor |
| chat_make_link($cm_id, $start, $end) X-Ref |
| constructs a valid link to a chat content param: cm_id the chat course module param: start the start time of the session param: end th end time of the session return: a well formed link to session display |
| chat_get_session_tracks($chat_id, $fromtime = 0, $totime = 0) X-Ref |
| fetches all the records for a given session and assemble them as a unique track we revamped here the code of report.php for making sessions, but without any output. note that we should collect sessions "by groups" if groupmode() is SEPARATEGROUPS. param: int $chat_id the database param: int $fromtime param: int $totime return: an array of objects representing the chat sessions. |
| chat_iterator() X-Ref |
| part of search engine API |
| chat_get_content_for_index(&$chat) X-Ref |
| part of search engine API |
| chat_single_document($id, $itemtype) X-Ref |
| returns a single data search document based on a chat_session id chat session id is a text composite identifier made of : - the chat id - the timestamp when the session starts - the timestamp when the session ends param: id the multipart chat session id param: itemtype the type of information (session is the only type) |
| chat_delete($info, $itemtype) X-Ref |
| dummy delete function that packs id with itemtype. this was here for a reason, but I can't remember it at the moment. |
| chat_db_names() X-Ref |
| returns the var names needed to build a sql query for addition/deletions // TODO chat indexable records are virtual. Should proceed in a special way |
| chat_check_text_access($path, $itemtype, $this_id, $user, $group_id, $context_id) X-Ref |
| this function handles the access policy to contents indexed as searchable documents. If this function does not exist, the search engine assumes access is allowed. When this point is reached, we already know that : - user is legitimate in the surrounding context - user may be guest and guest access is allowed to the module - the function may perform local checks within the module information logic param: path the access path to the module script code param: itemtype the information subclassing (usefull for complex modules, defaults to 'standard') param: this_id the item id within the information class denoted by entry_type. In chats, this id param: user the user record denoting the user who searches param: group_id the current group used by the user when searching return: true if access is allowed, false elsewhere |
| chat_link_post_processing($title) X-Ref |
| this call back is called when displaying the link for some last post processing |
| Generated: Wed Jan 14 11:33:29 2009 | Cross-referenced by PHPXref 0.7 |