1 | <?php |
||
14 | class Task extends EntityRepository |
||
15 | { |
||
16 | /** |
||
17 | * Maximum standby time. |
||
18 | * |
||
19 | * Between scans tasks can interpose new task. |
||
20 | * If no limit standby scheduler can not handle the new task before |
||
21 | * the arrival of the start time of the next task. |
||
22 | * For example the scheduler can expect a few days before the execution of the tasks |
||
23 | * that must be performed every hour. |
||
24 | * |
||
25 | * @var int |
||
26 | */ |
||
27 | const MAX_STANDBY_TIME = 3600; |
||
28 | |||
29 | /** |
||
30 | * @return TaskEntity|null |
||
31 | */ |
||
32 | public function getNextTask() |
||
49 | |||
50 | /** |
||
51 | * @return int |
||
52 | */ |
||
53 | public function getWaitingTime() |
||
82 | } |
||
83 |