Detailed Description
Class for processing schedule tasks.
- Author
- Dodonov A.A.
Definition at line 38 of file schedule.php.
Constructor & Destructor Documentation
Constructor.
- Exceptions
-
| Exception | - An exception of this type is thrown. |
- Author
- Dodonov A.A.
Definition at line 70 of file schedule.php.
{
try
{
$this->Database =
get_package(
'database' ,
'last' , __FILE__ );
$this->String =
get_package(
'string' ,
'last' , __FILE__ );
$this->ScheduleAccess =
get_package(
'schedule::schedule_access' ,
'last' , __FILE__ );
$this->ScheduleAlgorithms =
get_package(
'schedule::schedule_algorithms' ,
'last' , __FILE__ );
}
catch( Exception $e )
{
}
}
Member Function Documentation
Function processes tasks in the queue.
- Parameters
-
- Exceptions
-
| Exception | - An exception of this type is thrown. |
- Author
- Dodonov A.A.
Definition at line 270 of file schedule.php.
{
try
{
$this->ScheduleAccess->update( $Ids , array( 'processing' => 1 ) );
$this->Database->unlock();
foreach( $Tasks as $k => $Task )
{
}
}
catch( Exception $e )
{
}
}
Function processes task.
- Parameters
-
- Exceptions
-
| Exception | - An exception of this type is thrown. |
- Author
- Dodonov A.A.
Definition at line 235 of file schedule.php.
{
try
{
$NextIteration = $this->call_run_task_function( $Task );
$this->finish_task_processing( $Task , $NextIteration );
}
catch( Exception $e )
{
$this->Database->unlock();
$this->ScheduleAccess->update( $Task->id , array( 'processing' => 0 ) );
$this->Database->commit();
}
}
| run_task |
( |
|
$Parameters, |
|
|
|
$CurrentIteration |
|
) |
| |
Function processes task.
- Parameters
-
| $Parameters | - parameters of the task processing. |
| $CurrentIteration | - current interation. |
- Returns
- Next iteration.
- Exceptions
-
| Exception | - An exception of this type is thrown. |
- Author
- Dodonov A.A.
Definition at line 112 of file schedule.php.
{
try
{
$this->Settings->load_settings( $Parameters );
if( $this->Settings->get_setting( 'cron_ping' , '0' ) == 1 )
{
print( 'Cron ping' );
return( $CurrentIteration + 1 );
}
}
catch( Exception $e )
{
}
}
Function processes tasks in the queue.
- Exceptions
-
| Exception | - An exception of this type is thrown. |
- Author
- Dodonov A.A.
Definition at line 303 of file schedule.php.
{
try
{
$this->Database->lock( array( 'umx_schedule' ) , array( 'WRITE' ) );
$this->Settings->load_file( dirname( __FILE__ ).'/conf/cf_schedule_settings' );
$Tasks = $this->ScheduleAlgorithms->get_tasks(
$this->Settings->get_setting( 'processing_tasks_count' , 10 )
);
if( isset( $Tasks[ 0 ] ) )
{
}
else
{
$this->Database->unlock();
}
}
catch( Exception $e )
{
}
}
Field Documentation
Cached objects.
- Author
- Dodonov A.A.
Definition at line 50 of file schedule.php.
| $ScheduleAlgorithms = false |
The documentation for this class was generated from the following file: