//#region src/utils/runParallel/pidTree.d.ts
interface ListOptions {
  root?: boolean;
  advanced?: boolean;
}
type ProcessInfo = {
  pid: number;
  ppid?: number;
};
type ResultType<T extends ListOptions | undefined> = T extends {
  advanced: true;
} ? ProcessInfo[] : number[];
type ListCallback<T extends ListOptions | undefined> = (err: Error | null, list?: ResultType<T>) => void;
/**
 * Get the list of children pids of the given pid.
 * @param pid A PID. If -1 will return all the pids.
 * @param options Optional options object.
 * @param callback Called when the list is ready. If not provided a promise is returned instead.
 * @returns Only when the callback is not provided.
 */
declare const list: <T extends ListOptions | undefined>(pid: number | string, options?: T | ListCallback<T>, callback?: ListCallback<T>) => Promise<ResultType<T>> | undefined;
//#endregion
export { list };
//# sourceMappingURL=pidTree.d.ts.map