import { Correlation, FileSystem, FileSystemReadSync } from './api'; import { Directory, DirectoryContent, File, ShallowDirectory, SimpleStats } from './model'; import { InternalEventsEmitter } from './utils'; export declare namespace CacheFileSystem { interface Options { /** * should the cache re-sync when an error is reported from the underlying FS * default : true */ reSyncOnError?: boolean; /** * should sync read methods propagate to underlying FS * default : false */ propagateSyncRead?: boolean; } } export declare class CacheFileSystem implements FileSystemReadSync, FileSystem { private options; baseUrl: string; fs: FileSystem; private cache; readonly events: InternalEventsEmitter; private pathsInCache; private onFsError; constructor(fs: FileSystem, options?: CacheFileSystem.Options); private isPropagateSyncRead; private cacheTextFile; private cacheDirTree; private cacheDirChildren; private cacheStat; private cacheDirectoryGone; private cacheDirectoryExists; private cacheFileGone; saveFile(fullPath: string, newContent: string, correlation?: Correlation): Promise; deleteFile(fullPath: string, correlation?: Correlation): Promise; deleteDirectory(fullPath: string, recursive?: boolean, correlation?: Correlation): Promise; ensureDirectory(fullPath: string, correlation?: Correlation): Promise; loadTextFile(fullPath: string): Promise; loadTextFileSync(fullPath: string): string; loadDirectoryTree(fullPath?: string): Promise; loadDirectoryTreeSync(fullPath?: string): Directory; loadDirectoryContentSync(fullPath?: string): DirectoryContent; loadDirectoryChildren(fullPath: string): Promise<(File | ShallowDirectory)[]>; loadDirectoryChildrenSync(fullPath: string): Array; stat(fullPath: string): Promise; statSync(fullPath: string): SimpleStats; dispose(): void; private reSyncOnError; private emit; } //# sourceMappingURL=cache-fs.d.ts.map