-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathAuthCodeVerifyResponse.php
55 lines (43 loc) · 1.23 KB
/
AuthCodeVerifyResponse.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
namespace CurrencyFair\AppleId\Response;
class AuthCodeVerifyResponse
{
/** @var string */
private $accessToken;
/** @var string */
private $tokenType;
/** @var int */
private $expiresIn;
/** @var string */
private $refreshToken;
/** @var string */
private $idToken;
public function __construct(array $response)
{
$this->accessToken = isset($response['access_token']) ? $response['access_token'] : null;
$this->tokenType = isset($response['token_type']) ? $response['token_type'] : null;
$this->expiresIn = isset($response['expires_in']) ? $response['expires_in'] : null;
$this->refreshToken = isset($response['refresh_token']) ? $response['refresh_token'] : null;
$this->idToken = isset($response['id_token']) ? $response['id_token'] : null;
}
public function getAccessToken()
{
return $this->accessToken;
}
public function getTokenType()
{
return $this->tokenType;
}
public function getExpiresIn()
{
return $this->expiresIn;
}
public function getRefreshToken()
{
return $this->refreshToken;
}
public function getIdToken()
{
return $this->idToken;
}
}