All Downloads are FREE. Search and download functionalities are using the official Maven repository.

internal.util.http.StreamDecoder Maven / Gradle / Ivy

There is a newer version: 3.0.0-beta.13
Show newest version
package internal.util.http;

import org.checkerframework.checker.nullness.qual.NonNull;

import java.io.IOException;
import java.io.InputStream;

public interface StreamDecoder {

    @NonNull String getName();

    @NonNull InputStream decode(@NonNull InputStream stream) throws IOException;

    static @NonNull StreamDecoder noOp() {
        return HttpImpl.StreamDecoders.NONE;
    }

    static @NonNull StreamDecoder gzip() {
        return HttpImpl.StreamDecoders.GZIP;
    }

    static @NonNull StreamDecoder deflate() {
        return HttpImpl.StreamDecoders.DEFLATE;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy