import type { PluginsContainer } from "@webiny/plugins"; import { type ICompressedValue } from "./CompressionPlugin.js"; export interface ICompressorParams { plugins: PluginsContainer; } export interface ICompressor { disable(name: string): void; enable(name: string): void; /** * Compresses the given data using the first plugin that can compress it. */ compress(data: T): Promise; /** * Decompresses the given data using the first plugin that can decompress it. */ decompress(data: ICompressedValue | unknown): Promise; } declare class Compressor implements ICompressor { private readonly _plugins; private readonly disabled; private get plugins(); constructor(params: ICompressorParams); disable(name: string): void; enable(name: string): void; compress(data: T): Promise; decompress(data: ICompressedValue | unknown): Promise; } export declare const createDefaultCompressor: (params: ICompressorParams) => Compressor; export {};