Passed
Push — master ( e88490...575397 )
by Alexandre
04:15
created

Config::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: Alexandre
5
 * Date: 15/03/2018
6
 * Time: 21:56
7
 */
8
9
namespace OAuth2\Extensions\OpenID;
10
11
12
class Config extends \OAuth2\Config
13
{
14
    /**
15
     * @var string
16
     */
17
    private $issuerIdentifier;
18
19
    /**
20
     * @var int
21
     */
22
    protected $idTokenLifetime = 1800;
23
24
    public function __construct(string $issuerIdentifier)
25
    {
26
        parent::__construct();
27
        $this->issuerIdentifier = $issuerIdentifier;
28
    }
29
30
    /**
31
     * @return string
32
     */
33
    public function getIssuerIdentifier(): string
34
    {
35
        return $this->issuerIdentifier;
36
    }
37
38
    /**
39
     * @param string $issuerIdentifier
40
     */
41
    public function setIssuerIdentifier(string $issuerIdentifier): void
42
    {
43
        $this->issuerIdentifier = $issuerIdentifier;
44
    }
45
46
    /**
47
     * @return int
48
     */
49
    public function getIdTokenLifetime(): int
50
    {
51
        return $this->idTokenLifetime;
52
    }
53
54
    /**
55
     * @param int $idTokenLifetime
56
     */
57
    public function setIdTokenLifetime(int $idTokenLifetime): void
58
    {
59
        $this->idTokenLifetime = $idTokenLifetime;
60
    }
61
}