import { Stats, BigIntStats } from 'fs'; import { CreateReadStreamOptions, CreateWriteStreamOptions, FakeFS, ExtractHintOptions, WatchFileCallback, WatchFileOptions, StatWatcher, Dir, OpendirOptions, DirentNoPath } from './FakeFS'; import { Dirent, SymlinkType, StatSyncOptions, StatOptions } from './FakeFS'; import { MkdirOptions, RmdirOptions, RmOptions, WriteFileOptions, WatchCallback, WatchOptions, Watcher } from './FakeFS'; import { FSPath, Filename, Path } from './path'; export declare abstract class ProxiedFS

extends FakeFS

{ protected abstract readonly baseFs: FakeFS; /** * Convert a path from the user format into what should be fed into the internal FS. */ protected abstract mapToBase(path: P): IP; /** * Convert a path from the format supported by the base FS into the user one. */ protected abstract mapFromBase(path: IP): P; getExtractHint(hints: ExtractHintOptions): boolean; resolve(path: P): P; getRealPath(): P; openPromise(p: P, flags: string, mode?: number): Promise; openSync(p: P, flags: string, mode?: number): number; opendirPromise(p: P, opts?: OpendirOptions): Promise>; opendirSync(p: P, opts?: OpendirOptions): Dir

; readPromise(fd: number, buffer: Buffer, offset?: number, length?: number, position?: number | null): Promise; readSync(fd: number, buffer: Buffer, offset: number, length: number, position: number): number; writePromise(fd: number, buffer: Buffer, offset?: number, length?: number, position?: number): Promise; writePromise(fd: number, buffer: string, position?: number): Promise; writeSync(fd: number, buffer: Buffer, offset?: number, length?: number, position?: number): number; writeSync(fd: number, buffer: string, position?: number): number; closePromise(fd: number): Promise; closeSync(fd: number): void; createReadStream(p: P | null, opts?: CreateReadStreamOptions): import("fs").ReadStream; createWriteStream(p: P | null, opts?: CreateWriteStreamOptions): import("fs").WriteStream; realpathPromise(p: P): Promise

; realpathSync(p: P): P; existsPromise(p: P): Promise; existsSync(p: P): boolean; accessSync(p: P, mode?: number): void; accessPromise(p: P, mode?: number): Promise; statPromise(p: P): Promise; statPromise(p: P, opts: (StatOptions & { bigint?: false | undefined; }) | undefined): Promise; statPromise(p: P, opts: StatOptions & { bigint: true; }): Promise; statSync(p: P): Stats; statSync(p: P, opts?: StatSyncOptions & { bigint?: false | undefined; throwIfNoEntry: false; }): Stats | undefined; statSync(p: P, opts: StatSyncOptions & { bigint: true; throwIfNoEntry: false; }): BigIntStats | undefined; statSync(p: P, opts?: StatSyncOptions & { bigint?: false | undefined; }): Stats; statSync(p: P, opts: StatSyncOptions & { bigint: true; }): BigIntStats; statSync(p: P, opts: StatSyncOptions & { bigint: boolean; throwIfNoEntry?: false | undefined; }): Stats | BigIntStats; fstatPromise(fd: number): Promise; fstatPromise(fd: number, opts: { bigint: true; }): Promise; fstatPromise(fd: number, opts?: { bigint: boolean; }): Promise; fstatSync(fd: number): Stats; fstatSync(fd: number, opts: { bigint: true; }): BigIntStats; fstatSync(fd: number, opts?: { bigint: boolean; }): BigIntStats | Stats; lstatPromise(p: P): Promise; lstatPromise(p: P, opts: (StatOptions & { bigint?: false | undefined; }) | undefined): Promise; lstatPromise(p: P, opts: StatOptions & { bigint: true; }): Promise; lstatSync(p: P): Stats; lstatSync(p: P, opts?: StatSyncOptions & { bigint?: false | undefined; throwIfNoEntry: false; }): Stats | undefined; lstatSync(p: P, opts: StatSyncOptions & { bigint: true; throwIfNoEntry: false; }): BigIntStats | undefined; lstatSync(p: P, opts?: StatSyncOptions & { bigint?: false | undefined; }): Stats; lstatSync(p: P, opts: StatSyncOptions & { bigint: true; }): BigIntStats; lstatSync(p: P, opts: StatSyncOptions & { bigint: boolean; throwIfNoEntry?: false | undefined; }): Stats | BigIntStats; fchmodPromise(fd: number, mask: number): Promise; fchmodSync(fd: number, mask: number): void; chmodPromise(p: P, mask: number): Promise; chmodSync(p: P, mask: number): void; fchownPromise(fd: number, uid: number, gid: number): Promise; fchownSync(fd: number, uid: number, gid: number): void; chownPromise(p: P, uid: number, gid: number): Promise; chownSync(p: P, uid: number, gid: number): void; renamePromise(oldP: P, newP: P): Promise; renameSync(oldP: P, newP: P): void; copyFilePromise(sourceP: P, destP: P, flags?: number): Promise; copyFileSync(sourceP: P, destP: P, flags?: number): void; appendFilePromise(p: FSPath

, content: string | Uint8Array, opts?: WriteFileOptions): Promise; appendFileSync(p: FSPath

, content: string | Uint8Array, opts?: WriteFileOptions): void; writeFilePromise(p: FSPath

, content: string | NodeJS.ArrayBufferView, opts?: WriteFileOptions): Promise; writeFileSync(p: FSPath

, content: string | NodeJS.ArrayBufferView, opts?: WriteFileOptions): void; unlinkPromise(p: P): Promise; unlinkSync(p: P): void; utimesPromise(p: P, atime: Date | string | number, mtime: Date | string | number): Promise; utimesSync(p: P, atime: Date | string | number, mtime: Date | string | number): void; lutimesPromise(p: P, atime: Date | string | number, mtime: Date | string | number): Promise; lutimesSync(p: P, atime: Date | string | number, mtime: Date | string | number): void; mkdirPromise(p: P, opts?: MkdirOptions): Promise; mkdirSync(p: P, opts?: MkdirOptions): string | undefined; rmdirPromise(p: P, opts?: RmdirOptions): Promise; rmdirSync(p: P, opts?: RmdirOptions): void; rmPromise(p: P, opts?: RmOptions): Promise; rmSync(p: P, opts?: RmOptions): void; linkPromise(existingP: P, newP: P): Promise; linkSync(existingP: P, newP: P): void; symlinkPromise(target: P, p: P, type?: SymlinkType): Promise; symlinkSync(target: P, p: P, type?: SymlinkType): void; readFilePromise(p: FSPath

, encoding?: null): Promise; readFilePromise(p: FSPath

, encoding: BufferEncoding): Promise; readFilePromise(p: FSPath

, encoding?: BufferEncoding | null): Promise; readFileSync(p: FSPath

, encoding?: null): NonSharedBuffer; readFileSync(p: FSPath

, encoding: BufferEncoding): string; readFileSync(p: FSPath

, encoding?: BufferEncoding | null): NonSharedBuffer | string; readdirPromise(p: P, opts?: null): Promise>; readdirPromise(p: P, opts: { recursive?: false; withFileTypes: true; }): Promise>; readdirPromise(p: P, opts: { recursive?: false; withFileTypes?: false; }): Promise>; readdirPromise(p: P, opts: { recursive?: false; withFileTypes: boolean; }): Promise>; readdirPromise(p: P, opts: { recursive: true; withFileTypes: true; }): Promise>>; readdirPromise(p: P, opts: { recursive: true; withFileTypes?: false; }): Promise>; readdirPromise(p: P, opts: { recursive: true; withFileTypes: boolean; }): Promise | P>>; readdirPromise(p: P, opts: { recursive: boolean; withFileTypes: true; }): Promise | DirentNoPath>>; readdirPromise(p: P, opts: { recursive: boolean; withFileTypes?: false; }): Promise>; readdirPromise(p: P, opts: { recursive: boolean; withFileTypes: boolean; }): Promise | DirentNoPath | P>>; readdirSync(p: P, opts?: null): Array; readdirSync(p: P, opts: { recursive?: false; withFileTypes: true; }): Array; readdirSync(p: P, opts: { recursive?: false; withFileTypes?: false; }): Array; readdirSync(p: P, opts: { recursive?: false; withFileTypes: boolean; }): Array; readdirSync(p: P, opts: { recursive: true; withFileTypes: true; }): Array>; readdirSync(p: P, opts: { recursive: true; withFileTypes?: false; }): Array

; readdirSync(p: P, opts: { recursive: true; withFileTypes: boolean; }): Array | P>; readdirSync(p: P, opts: { recursive: boolean; withFileTypes: true; }): Array | DirentNoPath>; readdirSync(p: P, opts: { recursive: boolean; withFileTypes?: false; }): Array

; readdirSync(p: P, opts: { recursive: boolean; withFileTypes: boolean; }): Array | DirentNoPath | P>; readlinkPromise(p: P): Promise

; readlinkSync(p: P): P; truncatePromise(p: P, len?: number): Promise; truncateSync(p: P, len?: number): void; ftruncatePromise(fd: number, len?: number): Promise; ftruncateSync(fd: number, len?: number): void; watch(p: P, cb?: WatchCallback): Watcher; watch(p: P, opts: WatchOptions, cb?: WatchCallback): Watcher; watchFile(p: P, cb: WatchFileCallback): StatWatcher; watchFile(p: P, opts: WatchFileOptions, cb: WatchFileCallback): StatWatcher; unwatchFile(p: P, cb?: WatchFileCallback): void; private fsMapToBase; }