Total Complexity | 6 |
Total Lines | 77 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 0 |
1 | <?php |
||
12 | class GitHubApiConfiguration |
||
13 | { |
||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | private $clientId; |
||
18 | |||
19 | /** |
||
20 | * @var string |
||
21 | */ |
||
22 | private $clientSecret; |
||
23 | |||
24 | /** |
||
25 | * @var string |
||
26 | */ |
||
27 | private $redirectUrl; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | private $oauthAppName; |
||
33 | |||
34 | /** |
||
35 | * GitHubApiConfiguration constructor. |
||
36 | * @param string $clientId |
||
37 | * @param string $clientSecret |
||
38 | * @param string $redirectUrl |
||
39 | * @param string $oauthAppName |
||
40 | */ |
||
41 | public function __construct($clientId, $clientSecret, $redirectUrl, $oauthAppName) |
||
42 | { |
||
43 | $this->clientId = $clientId; |
||
44 | $this->clientSecret = $clientSecret; |
||
45 | $this->redirectUrl = $redirectUrl; |
||
46 | $this->oauthAppName = $oauthAppName; |
||
47 | } |
||
48 | |||
49 | /** |
||
50 | * @return string |
||
51 | */ |
||
52 | public function clientId() |
||
53 | { |
||
54 | return $this->clientId; |
||
55 | } |
||
56 | |||
57 | /** |
||
58 | * @return string |
||
59 | */ |
||
60 | public function clientSecret() |
||
61 | { |
||
62 | return $this->clientSecret; |
||
63 | } |
||
64 | |||
65 | /** |
||
66 | * @return string |
||
67 | */ |
||
68 | public function redirectUrl() |
||
69 | { |
||
70 | return $this->redirectUrl; |
||
71 | } |
||
72 | |||
73 | /** |
||
74 | * @return string |
||
75 | */ |
||
76 | public function oauthAppName() |
||
79 | } |
||
80 | |||
81 | /** |
||
82 | * This is just to identify that, we initiated the login sequence (not someone else) |
||
83 | * |
||
84 | * @return string |
||
85 | */ |
||
86 | public function ourSecretState() |
||
91 |