Client   A
last analyzed

Complexity

Total Complexity 5

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

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

5 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 7 1
A getId() 0 4 1
A getSecret() 0 4 1
A getRedirectUris() 0 4 1
A getAllowedGrantTypes() 0 4 1
1
<?php
2
/**
3
 * @author Boris Guéry <[email protected]>
4
 */
5
6
namespace Bgy\OAuth2;
7
8
class Client
9
{
10
    private $id;
11
    private $secret;
12
    private $redirectUris = [];
13
    private $allowedGrantTypes = [];
14
15
    public function __construct($id, $secret, array $redirectUris = [], array $allowedGrantTypes = [])
16
    {
17
        $this->id                = $id;
18
        $this->secret            = $secret;
19
        $this->redirectUris      = $redirectUris;
20
        $this->allowedGrantTypes = $allowedGrantTypes;
21
    }
22
23
    public function getId()
24
    {
25
        return $this->id;
26
    }
27
28
    public function getSecret()
29
    {
30
        return $this->secret;
31
    }
32
33
    public function getRedirectUris()
34
    {
35
        return $this->redirectUris;
36
    }
37
38
    public function getAllowedGrantTypes()
39
    {
40
        return $this->allowedGrantTypes;
41
    }
42
}
43