import * as chokidar from 'chokidar';
import type { FsEvent, FileInfo } from '../types';
export declare class Fs {
    cwd: string;
    ignored: string[];
    /**
     * Map of files to their details
     */
    protected filesList: Map<string, FileInfo>;
    protected watcher: Promise<chokidar.FSWatcher>;
    /**
     * List of callbacks to be called when the file system changes.
     */
    private callbacks;
    /**
     * A callback that wraps the original callbacks.
     * This is used to set async storage by cache module.
     */
    private emitWrapper;
    constructor(cwd: string, ignored?: string[]);
    getFileInfo(relativePath: string): Promise<FileInfo | undefined>;
    watch(cb: (events: FsEvent[]) => Promise<void> | void): Promise<void>;
    dispose(): Promise<void>;
    readdir(dir: string): Promise<FileInfo[]>;
    exists(file: string): Promise<boolean>;
    read(file: string, encoding?: BufferEncoding): Promise<string>;
    scan(pattern?: RegExp): Promise<FileInfo[]>;
    setEmitWrapper(wrapper: (fn: () => Promise<void> | void) => Promise<void> | void): void;
    emitCodeUpdated(): void;
    addVirtualFile(relativePath: string, sourceFileInfo: FileInfo): void;
    protected emit: (event: FsEvent) => void;
    private startWatcher;
}
//# sourceMappingURL=fs.d.ts.map