| @@ 202-211 (lines=10) @@ | ||
| 199 | * @throws PriorityException  | 
                                |
| 200 | * @throws ClassNotSubclassException  | 
                                |
| 201 | */  | 
                                |
| 202 | protected function validateSaveable(\Dtc\QueueBundle\Model\Job $job)  | 
                                |
| 203 |     { | 
                                |
| 204 |         if (null !== $job->getPriority() && null === $this->maxPriority) { | 
                                |
| 205 |             throw new PriorityException('This queue does not support priorities'); | 
                                |
| 206 | }  | 
                                |
| 207 | ||
| 208 |         if (!$job instanceof Job) { | 
                                |
| 209 |             throw new ClassNotSubclassException('Job needs to be instance of '.Job::class); | 
                                |
| 210 | }  | 
                                |
| 211 | }  | 
                                |
| 212 | ||
| 213 | /**  | 
                                |
| 214 | * @param null $workerName  | 
                                |
| @@ 288-297 (lines=10) @@ | ||
| 285 | * @throws PriorityException  | 
                                |
| 286 | * @throws ClassNotSubclassException  | 
                                |
| 287 | */  | 
                                |
| 288 | protected function validateSaveable(\Dtc\QueueBundle\Model\Job $job)  | 
                                |
| 289 |     { | 
                                |
| 290 |         if (null !== $job->getPriority() && null === $this->maxPriority) { | 
                                |
| 291 |             throw new PriorityException('This queue does not support priorities'); | 
                                |
| 292 | }  | 
                                |
| 293 | ||
| 294 |         if (!$job instanceof RetryableJob) { | 
                                |
| 295 |             throw new ClassNotSubclassException('Job needs to be instance of '.RetryableJob::class); | 
                                |
| 296 | }  | 
                                |
| 297 | }  | 
                                |
| 298 | ||
| 299 | protected function verifyGetJobArgs($workerName = null, $methodName = null, $prioritize = true)  | 
                                |
| 300 |     { | 
                                |