1 | <?php |
||
8 | class IntrospectionResponse extends AbstractResponseType |
||
9 | { |
||
10 | /** |
||
11 | * @var Token |
||
12 | */ |
||
13 | protected $token; |
||
14 | |||
15 | /** |
||
16 | * Set the token against the response |
||
17 | * |
||
18 | * @param Token $token |
||
19 | */ |
||
20 | 3 | public function setToken(Token $token) |
|
24 | |||
25 | /** |
||
26 | * Return wether the token has been set |
||
27 | * |
||
28 | * @return boolean |
||
29 | */ |
||
30 | 8 | private function hasToken() |
|
34 | |||
35 | /** |
||
36 | * @return array |
||
37 | */ |
||
38 | 3 | private function validTokenResponse() |
|
53 | |||
54 | /** |
||
55 | * @return array |
||
56 | */ |
||
57 | 5 | private function invalidTokenResponse() |
|
63 | |||
64 | /** |
||
65 | * Extract the introspection params from the token |
||
66 | * |
||
67 | * @return array |
||
68 | */ |
||
69 | 8 | public function getIntrospectionParams() |
|
75 | |||
76 | /** |
||
77 | * @param ResponseInterface $response |
||
78 | * |
||
79 | * @return ResponseInterface |
||
80 | */ |
||
81 | 2 | public function generateHttpResponse(ResponseInterface $response) |
|
95 | |||
96 | /** |
||
97 | * Add custom fields to your Introspection response here, then set your introspection |
||
98 | * reponse in AuthorizationServer::setIntrospectionResponseType() to pull in your version of |
||
99 | * this class rather than the default. |
||
100 | * |
||
101 | * @return array |
||
102 | */ |
||
103 | 2 | protected function getExtraParams() |
|
107 | } |
||
108 |