| 351 | } |
| 352 | |
| 353 | export class ComposedInteractor implements IInteractor { |
| 354 | constructor(private readonly interactors: IInteractor[]) { } |
| 355 | |
| 356 | get id(): string { |
| 357 | return 'composed'; |
| 358 | } |
| 359 | |
| 360 | async onData(data: string): Promise<IInteraction> { |
| 361 | for (const interactor of this.interactors) { |
| 362 | const result: IInteraction = await interactor.onData(data); |
| 363 | if (result.postAction === 'consume') { |
| 364 | return result; |
| 365 | } |
| 366 | } |
| 367 | |
| 368 | return { postAction: 'keep' }; |
| 369 | } |
| 370 | } |
| 371 | |
| 372 | export interface ISystemInteractor { |
| 373 | createTerminal(options: vscode.TerminalOptions): vscode.Terminal; |
nothing calls this directly
no outgoing calls
no test coverage detected