(private behavior: (m: CallMsg) => Action, readyOk: boolean | null = true)
| 46 | holdsTrimReport = false; |
| 47 | trims = 0; |
| 48 | constructor(private behavior: (m: CallMsg) => Action, readyOk: boolean | null = true) { |
| 49 | setTimeout(() => { if (this.alive && readyOk !== null) this.emitMessage({ type: 'ready', ok: readyOk }); }, 0); |
| 50 | } |
| 51 | on(event: string, cb: (...args: any[]) => void): void { |
| 52 | if (event === 'message') this.msgCb = cb; |
| 53 | else if (event === 'exit') this.exitCb = cb; |
nothing calls this directly
no test coverage detected