1 | <?php |
||
9 | class IntentManager |
||
10 | { |
||
11 | /** @var Intent[] */ |
||
12 | private $intents = []; |
||
13 | |||
14 | /** @var Intent */ |
||
15 | private $fallbackIntent; |
||
16 | |||
17 | /** |
||
18 | * Register intents. |
||
19 | * |
||
20 | * @param array $intents |
||
21 | * @param string $fallbackIntent |
||
22 | */ |
||
23 | public function register(array $intents, string $fallbackIntent): void |
||
26 | |||
27 | /** |
||
28 | * Find intent. |
||
29 | * |
||
30 | * @param ReceivedMessage $message |
||
31 | * |
||
32 | * @return Intent|null |
||
33 | */ |
||
34 | 3 | public function find(ReceivedMessage $message): ?Intent |
|
47 | |||
48 | /** |
||
49 | * Add intent. |
||
50 | * |
||
51 | * @param Intent $intent |
||
52 | */ |
||
53 | 3 | public function add(Intent $intent): void |
|
59 | |||
60 | /** |
||
61 | * Set fallback intent. |
||
62 | * |
||
63 | * @param Intent $intent |
||
64 | */ |
||
65 | 1 | public function setFallbackIntent(Intent $intent): void |
|
69 | } |
||
70 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.