UNPKG

805 BTypeScriptView Raw
1/// <reference types="node" />
2import { File } from './types';
3interface FileFsRefOptions {
4 mode?: number;
5 contentType?: string;
6 fsPath: string;
7}
8interface FromStreamOptions {
9 mode: number;
10 contentType?: string;
11 stream: NodeJS.ReadableStream;
12 fsPath: string;
13}
14declare class FileFsRef implements File {
15 type: 'FileFsRef';
16 mode: number;
17 fsPath: string;
18 contentType: string | undefined;
19 constructor({ mode, contentType, fsPath }: FileFsRefOptions);
20 static fromFsPath({ mode, contentType, fsPath, }: FileFsRefOptions): Promise<FileFsRef>;
21 static fromStream({ mode, contentType, stream, fsPath, }: FromStreamOptions): Promise<FileFsRef>;
22 toStreamAsync(): Promise<NodeJS.ReadableStream>;
23 toStream(): NodeJS.ReadableStream;
24}
25export = FileFsRef;