XPathExpressionDiscoverer   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 5
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A getFilteredCrawler() 0 3 1
1
<?php
2
namespace VDB\Spider\Discoverer;
3
4
use VDB\Spider\Discoverer\DiscovererInterface;
5
use VDB\Spider\Discoverer\CrawlerDiscoverer;
6
use VDB\Spider\Resource;
7
use VDB\Uri\Exception\UriSyntaxException;
8
use VDB\Uri\Uri;
9
use VDB\Spider\Uri\DiscoveredUri;
10
use VDB\Uri\UriInterface;
11
12
/**
13
 * @author Matthijs van den Bos
14
 * @copyright 2013 Matthijs van den Bos
15
 */
16
class XPathExpressionDiscoverer extends CrawlerDiscoverer
17
{
18
    protected function getFilteredCrawler(Resource $resource)
19
    {
20
        return $resource->getCrawler()->filterXPath($this->selector);
21
    }
22
}
23