Total Complexity | 5 |
Total Lines | 62 |
Duplicated Lines | 0 % |
Changes | 3 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
12 | class TrackSpamQuery extends Query |
||
13 | { |
||
14 | use Cacheable; |
||
15 | |||
16 | /** |
||
17 | * @var int |
||
18 | */ |
||
19 | private $limit; |
||
20 | |||
21 | /** |
||
22 | * TrackSpamQuery constructor. |
||
23 | * |
||
24 | * @param int $limit |
||
25 | */ |
||
26 | public function __construct(int $limit = 200) |
||
29 | } |
||
30 | |||
31 | /** |
||
32 | * Retrieve a Query builder. |
||
33 | * |
||
34 | * @return Builder |
||
35 | */ |
||
36 | protected function builder(): Builder |
||
37 | { |
||
38 | return TrackSpam::query(); |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | * Execute a DB query. |
||
43 | * |
||
44 | * @return Collection |
||
45 | */ |
||
46 | public function execute(): Collection |
||
51 | } |
||
52 | |||
53 | /** |
||
54 | * Retrieve the Query cache key. |
||
55 | * |
||
56 | * @return string |
||
57 | */ |
||
58 | public function cacheKey(): string |
||
61 | } |
||
62 | |||
63 | /** |
||
64 | * Invalidate the Query Cache for this Query. |
||
65 | * |
||
66 | * @return self |
||
67 | */ |
||
68 | public function invalidateCache() |
||
76 |