1 | <?php |
||
11 | class Api |
||
12 | { |
||
13 | /** |
||
14 | * @var Client client |
||
15 | */ |
||
16 | private $client; |
||
17 | |||
18 | /** |
||
19 | * @var MessageApi |
||
20 | */ |
||
21 | private $messageApi; |
||
22 | |||
23 | /** |
||
24 | * @var SpeechApi |
||
25 | */ |
||
26 | private $speechApi; |
||
27 | |||
28 | /** |
||
29 | * @var ConverseApi |
||
30 | */ |
||
31 | private $converseApi; |
||
32 | |||
33 | /** |
||
34 | * @param Client $client |
||
35 | */ |
||
36 | public function __construct(Client $client) |
||
43 | |||
44 | /** |
||
45 | * @deprecated This method is deprecated as of 0.1 and will be removed in 1.0. |
||
46 | * You should use the ConverseApi::converse() instead |
||
47 | * |
||
48 | * @param string $sessionId |
||
49 | * @param string $text |
||
50 | * @param Context|null $context |
||
51 | * |
||
52 | * @return array|null |
||
53 | */ |
||
54 | public function getConverseNextStep($sessionId, $text, Context $context = null) |
||
58 | |||
59 | /** |
||
60 | * @deprecated This method is deprecated as of 0.1 and will be removed in 1.0. |
||
61 | * You should use the MessageApi::extractMeaning() instead |
||
62 | * |
||
63 | * @param string $text |
||
64 | * @param Context|null $context |
||
65 | * @param array $extraParams |
||
66 | * |
||
67 | * @return array|null |
||
68 | */ |
||
69 | public function getIntentByText($text, Context $context = null, array $extraParams = []) |
||
73 | |||
74 | /** |
||
75 | * @deprecated This method is deprecated as of 0.1 and will be removed in 1.0. |
||
76 | * You should use the SpeechApi::extractMeaning() instead |
||
77 | * |
||
78 | * @param string|resource $file |
||
79 | * @param array|null $context |
||
80 | * @param array $queryParams |
||
81 | * |
||
82 | * @return array|null |
||
83 | */ |
||
84 | public function getIntentBySpeech($file, Context $context = null, array $queryParams = []) |
||
88 | |||
89 | /** |
||
90 | * @deprecated This method is deprecated as of 0.1 and will be removed in 1.0. |
||
91 | * |
||
92 | * @param string $messageId |
||
93 | * |
||
94 | * @return array|null |
||
95 | */ |
||
96 | public function getMessage($messageId) |
||
102 | |||
103 | /** |
||
104 | * @return Client |
||
105 | */ |
||
106 | public function getClient() |
||
110 | |||
111 | /** |
||
112 | * @deprecated This method is deprecated as of 0.1 and will be removed in 1.0. |
||
113 | * You should use the ResponseHandler::decodeResponse() instead |
||
114 | * |
||
115 | * @param ResponseInterface $response |
||
116 | * |
||
117 | * @return array|null |
||
118 | */ |
||
119 | protected function decodeResponse(ResponseInterface $response) |
||
123 | } |
||
124 |
This method has been deprecated. The supplier of the class has supplied an explanatory message.
The explanatory message should give you some clue as to whether and when the method will be removed from the class and what other method or class to use instead.