import StreamCompressor from './streamCompressor.js';
export default class DeflateCompressor extends StreamCompressor {
    get id() {
        return `dfl`;
    }
    get algorithm() {
        return 'deflate-raw';
    }
    async compress(input) {
        const result = await super.compress(input);
        return result.replace(/\+/g, '-').replace(/\//g, '_');
    }
    async decompress(input) {
        input = input.replace(/-/g, '+').replace(/_/g, '/');
        return await super.decompress(input);
    }
}
