commercetools-sdk-php-v2  master
The platform, import-api and ml-api PHP sdks generated from our api reference.
RefreshableTokenModel.php
1 <?php
2 
3 declare(strict_types=1);
4 
5 namespace Commercetools\Client;
6 
10 class RefreshableTokenModel implements Token
11 {
13  private $value;
14 
16  private $expiresIn;
17 
19  private $refreshToken;
20 
21  public function __construct(string $value, int $expiresIn = null, ?string $refreshToken = null)
22  {
23  $this->value = $value;
24  $this->expiresIn = $expiresIn ?? 0;
25  $this->refreshToken = $refreshToken;
26  }
27 
28  public function getValue(): string
29  {
30  return $this->value;
31  }
32 
33  public function getExpiresIn(): int
34  {
35  return $this->expiresIn;
36  }
37 
38  public function getRefreshToken(): ?string
39  {
40  return $this->refreshToken;
41  }
42 }
__construct(string $value, int $expiresIn=null, ?string $refreshToken=null)