|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| cron () | |
| full_tag_found_in_cache ($tagname, $latestline) | |
| remove_tag_from_cache ($tagname) | |
| get_recstatus ($tagdata, $tagname) | |
| process_group_tag ($tagcontents) | |
| process_person_tag ($tagcontents) | |
| process_membership_tag ($tagcontents) | |
| process_properties_tag ($tagcontents) | |
| log_line ($string) | |
| decode_timeframe ($string) | |
| load_role_mappings () | |
Data Fields | |
| $log | |
| cron | ( | ) |
Read in an IMS Enterprise file. Originally designed to handle v1.1 files but should be able to handle earlier types as well, I believe.
Reimplemented from enrol_plugin.
Definition at line 66 of file lib.php.

| decode_timeframe | ( | $ | string | ) |
| full_tag_found_in_cache | ( | $ | tagname, |
| $ | latestline | ||
| ) |
Check if a complete tag is found in the cached data, which usually happens when the end of the tag has only just been loaded into the cache. Returns either false, or the contents of the tag (including start and end).
| string | $tagname | Name of tag to look for |
| string | $latestline | The very last line in the cache (used for speeding up the match) |
Definition at line 265 of file lib.php.

| get_recstatus | ( | $ | tagdata, |
| $ | tagname | ||
| ) |
Very simple convenience function to return the "recstatus" found in person/group/role tags. 1=Add, 2=Update, 3=Delete, as specified by IMS, and we also use 0 to indicate "unspecified".
| string | $tagdata | the tag XML data |
| string | $tagname | the name of the tag we're interested in |
Definition at line 291 of file lib.php.

| log_line | ( | $ | string | ) |
Store logging information. This does two things: uses the mtrace() function to print info to screen/STDOUT, and also writes log to a text file if a path has been specified.
| string | $string | Text to write (newline will be added automatically) |
Definition at line 748 of file lib.php.


| process_group_tag | ( | $ | tagcontents | ) |
| process_membership_tag | ( | $ | tagcontents | ) |
Process the membership tag. This defines whether the specified Moodle users should be added/removed as teachers/students.
| string | $tagconents | The raw contents of the XML element |
Definition at line 580 of file lib.php.


| process_person_tag | ( | $ | tagcontents | ) |
| process_properties_tag | ( | $ | tagcontents | ) |
Process the properties tag. The only data from this element that is relevant is whether a <target> is specified.
| string | $tagconents | The raw contents of the XML element |
Definition at line 731 of file lib.php.


| remove_tag_from_cache | ( | $ | tagname | ) |
Remove complete tag from the cached data (including all its contents) - so that the cache doesn't grow to unmanageable size
| string | $tagname | Name of tag to look for |
echo "<p>remove_tag_from_cache: $tagname</p>"; flush(); ob_flush();
Definition at line 278 of file lib.php.
