/// <reference types="node" />
import { ChunkSource, FileInfo, FileSystem } from '@chunkd/core';
import { Readable } from 'stream';
export declare function toBuffer(stream: Readable): Promise<Buffer>;
export declare function toReadable(r: string | Buffer | Readable): Readable;
export declare class FsMemory implements FileSystem {
    protocol: string;
    files: Map<string, Buffer>;
    read(filePath: string): Promise<Buffer>;
    stream(filePath: string): Readable;
    write(filePath: string, buffer: string | Buffer | Readable): Promise<void>;
    list(filePath: string): AsyncGenerator<string>;
    details(filePath: string): AsyncGenerator<FileInfo>;
    exists(filePath: string): Promise<boolean>;
    head(filePath: string): Promise<FileInfo | null>;
    source(): ChunkSource;
}
//# sourceMappingURL=memory.fs.d.ts.map