Completed
Pull Request — master (#87)
by Peter
01:11
created

CrawlQueue::getPendingUrlAtIndex()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 9.4285
c 0
b 0
f 0
cc 2
eloc 4
nc 2
nop 1
1
<?php
2
3
namespace Spatie\Crawler;
4
5
interface CrawlQueue
6
{
7
    public function add(CrawlUrl $url): self;
8
9
    public function has($crawlUrl): bool;
10
11
    public function hasPendingUrls(): bool;
12
13
    public function getUrlById(int $id): CrawlUrl;
14
15
    /** @return \Spatie\Crawler\CrawlUrl|null */
16
    public function getFirstPendingUrl();
17
18
    public function hasAlreadyBeenProcessed(CrawlUrl $url);
19
20
    public function markAsProcessed(CrawlUrl $crawlUrl);
21
}
22