export interface ChildManagerOptions { execPath: string; scriptPath: string; extraArgs: string[]; cwd: string; killGraceMs?: number; /** How long a suspending child gets to release its resources (default: 15s). */ suspendGraceMs?: number; } export interface ChildExitInfo { code: number | null; signal: NodeJS.Signals | null; } export interface ChildStreams { stdout: NodeJS.ReadableStream; stdin: NodeJS.WritableStream; } export declare class ChildManager { private readonly opts; private child; private onExitCallback; private readonly killGraceMs; private readonly suspendGraceMs; constructor(opts: ChildManagerOptions); /** Registered once; fires for every child this instance ever spawns. */ onExit(callback: (info: ChildExitInfo) => void): void; spawn(): ChildStreams; isRunning(): boolean; /** * Ask the child to release everything it holds - Chrome, managed dev * servers, monitors - and exit, resolving once it has actually gone. * * SIGUSR2 rather than SIGUSR1 because Node reserves SIGUSR1 for starting its * own inspector, and it is sent to the child alone rather than to its * process group: the point is to give the child a chance to shut its own * children down in order, not to kill them out from under it. If it doesn't * finish in time, kill() escalates through the usual SIGTERM/SIGKILL path. */ suspend(): Promise; /** Kill the current child (if any) and resolve once it has actually exited. */ kill(): Promise; } //# sourceMappingURL=child-manager.d.ts.map