(
request: GetCompletionsRequest
)
| 189 | } |
| 190 | |
| 191 | async getCompletions( |
| 192 | request: GetCompletionsRequest |
| 193 | ): Promise<GetCompletionsResponse | undefined> { |
| 194 | const requestId = Number(request.metadata?.requestId); |
| 195 | const prom = new Promise<GetCompletionsResponse | undefined>((resolve) => { |
| 196 | this.promiseMap.set(requestId, resolve); |
| 197 | }); |
| 198 | const message: GetCompletionsRequestMessage = { |
| 199 | kind: 'getCompletions', |
| 200 | requestId, |
| 201 | request: request.toJsonString(), |
| 202 | }; |
| 203 | this.port.postMessage(message); |
| 204 | return prom; |
| 205 | } |
| 206 | |
| 207 | acceptedLastCompletion(ideInfo: IdeInfo, apiKey: string, completionId: string): void { |
| 208 | const request = new AcceptCompletionRequest({ |
no outgoing calls
no test coverage detected