1 | export type DetectPortCallback = (err: Error | null, port?: number) => void;
|
2 | export interface PortConfig {
|
3 | port?: number | string;
|
4 | hostname?: string | undefined;
|
5 | callback?: DetectPortCallback;
|
6 | }
|
7 | export declare class IPAddressNotAvailableError extends Error {
|
8 | constructor(options?: ErrorOptions);
|
9 | }
|
10 | export declare function detectPort(port?: number | PortConfig | string): Promise<number>;
|
11 | export declare function detectPort(callback: DetectPortCallback): void;
|
12 | export declare function detectPort(port: number | PortConfig | string | undefined, callback: DetectPortCallback): void;
|