1 | <?php |
||
7 | class ScheduledRun extends DataObject |
||
|
|||
8 | { |
||
9 | /** |
||
10 | * @var array |
||
11 | */ |
||
12 | private static $db = array( |
||
13 | 'Type' => 'Varchar(128)', |
||
14 | ); |
||
15 | |||
16 | /** |
||
17 | * Triggered by ScheduledExecutionJob this will add another job for the actual work. |
||
18 | * |
||
19 | * This "forking" of another process simply happens to make sure the scheduled process doesn't |
||
20 | * get delayed further and further because of the actual execution time. |
||
21 | */ |
||
22 | public function onScheduledExecution() |
||
33 | |||
34 | /** |
||
35 | * Gets a singleton instance of the job, referred to as "Type" |
||
36 | * |
||
37 | * @return DataObject|null |
||
38 | */ |
||
39 | public function getTypeInstance() |
||
43 | |||
44 | /** |
||
45 | * delivers the title for the job queue |
||
46 | * |
||
47 | * @return string |
||
48 | */ |
||
49 | public function getTitle() |
||
53 | } |
||
54 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.