1 | <?php |
||
12 | class RefreshTokenRepository implements RefreshTokenRepositoryInterface |
||
13 | { |
||
14 | /** |
||
15 | * The event dispatcher instance. |
||
16 | * |
||
17 | * @var \Illuminate\Contracts\Events\Dispatcher |
||
18 | */ |
||
19 | protected $events; |
||
20 | |||
21 | /** |
||
22 | * Create a new repository instance. |
||
23 | * |
||
24 | * @param \Illuminate\Contracts\Events\Dispatcher $events |
||
25 | * |
||
26 | * @return void |
||
|
|||
27 | */ |
||
28 | public function __construct(Dispatcher $events) |
||
32 | |||
33 | /** |
||
34 | * {@inheritdoc} |
||
35 | */ |
||
36 | public function getNewRefreshToken() |
||
40 | |||
41 | /** |
||
42 | * {@inheritdoc} |
||
43 | */ |
||
44 | public function persistNewRefreshToken(RefreshTokenEntityInterface $refreshTokenEntity) |
||
53 | |||
54 | /** |
||
55 | * Revokes the refresh token. |
||
56 | * |
||
57 | * @param string $identifier |
||
58 | * |
||
59 | * @return mixed |
||
60 | */ |
||
61 | public function revokeRefreshToken($identifier) |
||
65 | |||
66 | /** |
||
67 | * Checks if the refresh token has been revoked. |
||
68 | * |
||
69 | * @param string $identifier |
||
70 | * |
||
71 | * @return bool |
||
72 | */ |
||
73 | public function isRefreshTokenRevoked($identifier) |
||
81 | } |
||
82 |
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.