1 | <?php declare(strict_types=1); |
||
38 | trait ImplicitGrantTrait |
||
39 | { |
||
40 | /** |
||
41 | * @var ImplicitIntegrationInterface |
||
42 | */ |
||
43 | private $implicitIntegration; |
||
44 | 44 | ||
45 | /** |
||
46 | 44 | * @param ImplicitIntegrationInterface $integration |
|
47 | * |
||
48 | * @return void |
||
49 | */ |
||
50 | public function implicitSetIntegration(ImplicitIntegrationInterface $integration): void |
||
54 | 4 | ||
55 | /** |
||
56 | * @return ImplicitIntegrationInterface |
||
57 | */ |
||
58 | protected function implicitGetIntegration(): ImplicitIntegrationInterface |
||
62 | 7 | ||
63 | /** |
||
64 | 7 | * @param string[] $parameters |
|
65 | * |
||
66 | * @return string|null |
||
67 | */ |
||
68 | protected function implicitGetClientId(array $parameters): ?string |
||
72 | 7 | ||
73 | /** |
||
74 | 7 | * @param string[] $parameters |
|
75 | * |
||
76 | * @return string|null |
||
77 | */ |
||
78 | protected function implicitGetRedirectUri(array $parameters): ?string |
||
82 | 4 | ||
83 | /** |
||
84 | 4 | * @param string[] $parameters |
|
85 | * |
||
86 | 4 | * @return string[]|null |
|
|
|||
87 | */ |
||
88 | protected function implicitGetScope(array $parameters): ?array |
||
94 | 6 | ||
95 | /** |
||
96 | 6 | * @param string[] $parameters |
|
97 | * |
||
98 | * @return string|null |
||
99 | */ |
||
100 | protected function implicitGetState(array $parameters): ?string |
||
104 | |||
105 | /** |
||
106 | * @param string[] $parameters |
||
107 | 6 | * @param ClientInterface $client |
|
108 | * @param string|null $redirectUri |
||
109 | * @param int|null $maxStateLength |
||
110 | * |
||
111 | * @return ResponseInterface |
||
112 | */ |
||
113 | 6 | protected function implicitAskResourceOwnerForApproval( |
|
158 | |||
159 | 7 | /** |
|
160 | * @param array $parameters |
||
161 | 7 | * @param string $name |
|
162 | 7 | * |
|
163 | * @return null|string |
||
164 | */ |
||
165 | private function implicitReadStringValue(array $parameters, string $name): ?string |
||
170 | } |
||
171 |
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.If the return type contains the type array, this check recommends the use of a more specific type like
String[]
orarray<String>
.