Stud.IP  6.0
CronJob Class Reference
Inheritance diagram for CronJob:
CheckAdmissionJob CleanupLogJob CoursewareCronjob Cronjob GarbageCollectorJob ImportIliasTestresults PurgeCacheJob RemindOerUpload SendMailNotificationsJob SendMailQueueJob SessionGcJob

Public Member Functions

 execute ($last_result, $parameters=[])
 setUp ()
 tearDown ()

Static Public Member Functions

static getName ()
static getDescription ()
static getParameters ()
static register ()
static unregister ()

Member Function Documentation

◆ execute()

execute (   $last_result,
  $parameters = [] 

Execute the cronjob.

mixed$last_resultWhat the last execution of this cronjob returned.
Array$parametersParameters for this cronjob instance which were defined during scheduling.

◆ getDescription()

static getDescription ( )

Return the description of the cronjob.

◆ getName()

static getName ( )

Return the name of the cronjob.

◆ getParameters()

static getParameters ( )

Returns a list of available parameters for this cronjob.

Each parameter is an entry in the resulting with a unique identifier with the following array fields:

  • "type" which is one of the following:
    • boolean, a simple binary option
    • string, a single line of text
    • text, a multiline chunk of text
    • integer, a number
    • select, a defined set of values (define in the field "values" as an array)
  • "default" provides a default value for this field (optional)
  • "status" is either "optional" or "mandatory" (optional, defaults to optional)
  • "description" provides a decription for this parameter


return array( 'area' => array( 'type' => 'select', 'values' => array('seminar', 'institute', 'user'), 'description' => 'Example parameter #1', ), 'verbose' => array( 'type' => 'boolean', 'default' => false, 'status' => 'optional', 'description' => 'Example parameter #2', ), );

ArrayList of paramters in the format described above.

◆ register()

static register ( )

Registers the cronjob and/or returns the corresponding task.

CronjobTask Task for this cronjob

◆ setUp()

setUp ( )

Setup method.

◆ tearDown()

tearDown ( )

Teardown method.

◆ unregister()

static unregister ( )

Unregisters a previously registered task.

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