1 |
|
2 |
|
3 | import { PassThrough } from "stream";
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 | declare function merge2(options?: merge2.Options): merge2.Merge2Stream;
|
20 | declare function merge2(a: Streams, options?: merge2.Options): merge2.Merge2Stream;
|
21 | declare function merge2(a: Streams, b: Streams, options?: merge2.Options): merge2.Merge2Stream;
|
22 | declare function merge2(a: Streams, b: Streams, c: Streams, options?: merge2.Options): merge2.Merge2Stream;
|
23 | declare function merge2(a: Streams, b: Streams, c: Streams, d: Streams, options?: merge2.Options): merge2.Merge2Stream;
|
24 | declare function merge2(
|
25 | a: Streams,
|
26 | b: Streams,
|
27 | c: Streams,
|
28 | d: Streams,
|
29 | e: Streams,
|
30 | options?: merge2.Options,
|
31 | ): merge2.Merge2Stream;
|
32 | declare function merge2(...args: Streams[]): merge2.Merge2Stream;
|
33 |
|
34 | type Streams = merge2.StreamType | merge2.StreamType[];
|
35 |
|
36 | declare namespace merge2 {
|
37 | type StreamType = NodeJS.ReadableStream | Merge2Stream;
|
38 |
|
39 | interface Options {
|
40 | end?: boolean | undefined;
|
41 | pipeError?: boolean | undefined;
|
42 | objectMode?: boolean | undefined;
|
43 | }
|
44 |
|
45 | interface Merge2Stream extends PassThrough {
|
46 | |
47 |
|
48 |
|
49 |
|
50 |
|
51 |
|
52 |
|
53 | add(...args: Streams[]): Merge2Stream;
|
54 |
|
55 | |
56 |
|
57 |
|
58 |
|
59 |
|
60 |
|
61 |
|
62 |
|
63 |
|
64 | on(event: "queueDrain", listener: () => void): this;
|
65 | on(event: string, listener: (...args: any[]) => void): this;
|
66 |
|
67 | once(event: "queueDrain", listener: () => void): this;
|
68 | once(event: string, listener: (...args: any[]) => void): this;
|
69 | }
|
70 | }
|
71 |
|
72 | export = merge2;
|