Class CronJob

Description

CronJob is a single cron task

Located in /system/classes/cronjob.php (line 20)

QueryRecord
   |
   --CronJob
Class Constant Summary
Method Summary
static array default_fields ()
CronJob __construct ([array $paramarray = array()])
bool delete ()
void execute ()
mixed __get (string $name)
mixed __set (string $name, mixed $value)
Variables
Methods
static method default_fields (line 40)

Returns the defined database columns for a cronjob.

  • return: Array of default columns in the crontab table
  • access: public
static array default_fields ()
Constructor __construct (line 64)

Constructor for the CronJob class.

CronJob __construct ([array $paramarray = array()])
  • array $paramarray: an associative array or querystring of initial field values

Redefinition of:
QueryRecord::__construct()
constructor __construct Constructor for the QueryRecord class.
delete (line 210)

Deletes an existing cron job.

bool delete ()

Redefinition of:
QueryRecord::delete()
This is the public interface that deletes a record
execute (line 104)

Runs this job.

Executes the Cron Job callback. Deletes the Cron Job if end_time is reached or if it failed to execute the last # consecutive attempts. Also sends notification by email to specified address. Note: end_time can be null, ie. "The Never Ending Cron Job".

Callback is passed a param_array of the Cron Job fields and the execution time as the 'now' field. The 'result' field contains the result of the last execution; either 'executed' or 'failed'.

  • todo: send notification of execution/failure.
  • todo: delete job after # failed attempts.
  • access: public
void execute ()
insert (line 188)

Saves a new cron job to the crontab table.

CronJob insert ()

Redefinition of:
QueryRecord::insert()
This is the public interface that inserts a record
update (line 199)

Updates an existing cron job to the crontab table.

CronJob update ()

Redefinition of:
QueryRecord::update()
This is the public interface that updates a record
__get (line 171)

Magic property getter to get the cronjob properties.

Unserializes the callback if called.

  • return: The value of the property, or null if no property by that name.
  • see: QueryRecord::__get()
  • access: public
mixed __get (string $name)
  • string $name: The name of the property to get.

Redefinition of:
QueryRecord::__get()
function __get
__set (line 143)

Magic property setter to set the cronjob properties.

Serializes the callback if needed.

mixed __set (string $name, mixed $value)
  • string $name: The name of the property to set.
  • mixed $value: The value of the property to set.

Redefinition of:
QueryRecord::__set()
function __set

Inherited Methods

Inherited From QueryRecord

QueryRecord::__construct()
QueryRecord::delete()
QueryRecord::deleteRecord()
QueryRecord::exclude_fields()
QueryRecord::get_url_args()
QueryRecord::insert()
QueryRecord::insertRecord()
QueryRecord::list_excluded_fields()
QueryRecord::to_array()
QueryRecord::update()
QueryRecord::updateRecord()
QueryRecord::__get()
QueryRecord::__isset()
QueryRecord::__set()
Class Constants
CRON_CUSTOM = 8 (line 25)
CRON_PLUGIN = 4 (line 24)
CRON_SYSTEM = 1 (line 22)
CRON_THEME = 2 (line 23)

Documentation generated on Thu, 30 Oct 2008 20:31:07 +0100 by phpDocumentor 1.3.2