Completed
Push — master ( 512542...4d85fd )
by Jan-Petter
02:22
created

DelayCore   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 46
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
c 1
b 0
f 0
lcom 0
cbo 0
dl 0
loc 46
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getBaseUri() 0 4 1
A getUserAgent() 0 4 1
1
<?php
2
namespace vipnytt\RobotsTxtParser\Client\Directives;
3
4
/**
5
 * Class DelayCore
6
 *
7
 * @package vipnytt\RobotsTxtParser\Client\Directives
8
 */
9
abstract class DelayCore implements DelayInterface
10
{
11
    /**
12
     * Base Uri
13
     * @var string
14
     */
15
    protected $base;
16
17
    /**
18
     * User-agent
19
     * @var string
20
     */
21
    protected $userAgent;
22
23
    /**
24
     * DelayClient constructor.
25
     *
26
     * @param string $baseUri
27
     * @param string $userAgent
28
     */
29
    public function __construct($baseUri, $userAgent)
30
    {
31
        $this->base = $baseUri;
32
        $this->userAgent = $userAgent;
33
    }
34
35
    /**
36
     * Get base uri
37
     *
38
     * @return string
39
     */
40
    public function getBaseUri()
41
    {
42
        return $this->base;
43
    }
44
45
    /**
46
     * Get User-agent string
47
     *
48
     * @return string
49
     */
50
    public function getUserAgent()
51
    {
52
        return $this->userAgent;
53
    }
54
}
55