Differences Between: [Versions 310 and 403] [Versions 39 and 403]
This file contains the forms to create and edit an instance of this module
Copyright: | 2012 NetSpot {@link http://www.netspot.com.au} |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 216 lines (8 kb) |
Included or required: | 0 times |
Referenced: | 1 time |
Includes or requires: | 0 files |
assignfeedback_offline_grade_importer:: (7 methods):
__construct()
parsecsv()
init()
get_encoding()
get_separator()
next()
close()
Class: assignfeedback_offline_grade_importer - X-Ref
CSV Grade importer__construct($importid, assign $assignment, $encoding = 'utf-8', $separator = 'comma') X-Ref |
Constructor param: string $importid A unique id for this import param: assign $assignment The current assignment |
parsecsv($csvdata) X-Ref |
Parse a csv file and save the content to a temp file Should be called before init() param: string $csvdata The csv data return: bool false is a failed import |
init() X-Ref |
Initialise the import reader and locate the column indexes. return: bool false is a failed import |
get_encoding() X-Ref |
Return the encoding for this csv import. return: string The encoding for this csv import. |
get_separator() X-Ref |
Return the separator for this csv import. return: string The separator for this csv import. |
next() X-Ref |
Get the next row of data from the csv file (only the columns we care about) return: stdClass or false The stdClass is an object containing user, grade and lastmodified |
close($delete) X-Ref |
Close the grade importer file and optionally delete any temp files param: bool $delete |