Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
Public Member Functions | Public Attributes | Protected Attributes | List of all members
tool_uploadcourse_tracker Class Reference

Class output tracker. More...

Public Member Functions

 __construct ($outputmode=self::NO_OUTPUT)
 Constructor. More...
 
 finish ()
 Finish the output. More...
 
 output ($line, $outcome, $status, $data)
 Output one more line. More...
 
 results ($total, $created, $updated, $deleted, $errors)
 Output the results. More...
 
 start ()
 Start the output. More...
 

Public Attributes

const NO_OUTPUT = 0
 Constant to output nothing.
 
const OUTPUT_HTML = 1
 Constant to output HTML.
 
const OUTPUT_PLAIN = 2
 Constant to output plain text.
 

Protected Attributes

object $buffer
 output buffer.
 
array $columns = array('line', 'result', 'id', 'shortname', 'fullname', 'idnumber', 'status')
 columns to display.
 
int $outputmode
 chosen output mode.
 
int $rownb = 0
 row number.
 

Detailed Description

Class output tracker.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Constructor & Destructor Documentation

◆ __construct()

tool_uploadcourse_tracker::__construct (   $outputmode = self::NO_OUTPUT)

Constructor.

Parameters
int$outputmodedesired output mode.

Member Function Documentation

◆ finish()

tool_uploadcourse_tracker::finish ( )

Finish the output.

Return values
void

◆ output()

tool_uploadcourse_tracker::output (   $line,
  $outcome,
  $status,
  $data 
)

Output one more line.

Parameters
int$lineline number.
bool$outcomesuccess or not?
array$statusarray of statuses.
array$dataextra data to display.
Return values
void

◆ results()

tool_uploadcourse_tracker::results (   $total,
  $created,
  $updated,
  $deleted,
  $errors 
)

Output the results.

Parameters
int$totaltotal courses.
int$createdcount of courses created.
int$updatedcount of courses updated.
int$deletedcount of courses deleted.
int$errorscount of errors.
Return values
void

◆ start()

tool_uploadcourse_tracker::start ( )

Start the output.

Return values
void

The documentation for this class was generated from the following file: