Свойство | Type | Description | |
---|---|---|---|
$baseUrl | |||
$baseUrl | Spatie\Crawler\Url; | ||
$client | |||
$concurrency | integer | ||
$crawlObserver | Spatie\Crawler\CrawlObserver | ||
$crawlProfile | Spatie\Crawler\CrawlProfile | ||
$crawlQueue | |||
$crawledUrls |
Méthode | Description | |
---|---|---|
__construct ( |
||
__construct ( |
||
create ( ) : static | ||
create ( array $clientOptions = [] ) : static | ||
setConcurrency ( integer $concurrency ) | ||
setCrawlObserver ( Spatie\Crawler\CrawlObserver $crawlObserver ) | ||
setCrawlProfile ( Spatie\Crawler\CrawlProfile $crawlProfile ) | ||
startCrawling ( |
Méthode | Description | |
---|---|---|
addAllLinksToCrawlQueue ( string $html, |
||
crawlAllLinks ( string $html ) | Crawl all links in the given html. | |
crawlUrl ( |
Crawl the given url. | |
extractAllLinks ( string $html ) : |
||
getAllLinks ( string $html ) : |
Get all links in the given html. | |
getCrawlRequests ( ) : Generato\Generator | ||
handleResponse ( Psr\Http\Message\ResponseInterface | null $response, integer $index ) | ||
hasAlreadyCrawled ( |
Determine if the crawled has already crawled the given url. | |
normalizeUrl ( |
Normalize the given url. | |
normalizeUrl ( |
||
startCrawlingQueue ( ) |
public __construct ( |
||
$client | ||
$concurrency | integer |
protected addAllLinksToCrawlQueue ( string $html, |
||
$html | string | |
$foundOnUrl |
protected crawlAllLinks ( string $html ) | ||
$html | string |
protected extractAllLinks ( string $html ) : |
||
$html | string | |
Résultat |
protected getAllLinks ( string $html ) : |
||
$html | string | |
Résultat |
protected getCrawlRequests ( ) : Generato\Generator | ||
Résultat | Generato\Generator |
protected handleResponse ( Psr\Http\Message\ResponseInterface | null $response, integer $index ) | ||
$response | Psr\Http\Message\ResponseInterface | null | |
$index | integer |
protected hasAlreadyCrawled ( |
||
$url | ||
Résultat | boolean |
protected normalizeUrl ( |
||
$url |
public setCrawlObserver ( Spatie\Crawler\CrawlObserver $crawlObserver ) | ||
$crawlObserver | Spatie\Crawler\CrawlObserver |
public setCrawlProfile ( Spatie\Crawler\CrawlProfile $crawlProfile ) | ||
$crawlProfile | Spatie\Crawler\CrawlProfile |
protected CrawlObserver,Spatie\Crawler $crawlObserver | ||
Résultat | Spatie\Crawler\CrawlObserver |
protected CrawlProfile,Spatie\Crawler $crawlProfile | ||
Résultat | Spatie\Crawler\CrawlProfile |
protected CrawlQueue,Spatie\Crawler $crawlQueue | ||
Résultat |