forked from mirror/BlueMap
Add zlib and zstd to the usable compression formats
(They are available in the dependencies anyways so why not add them here ^^)
This commit is contained in:
parent
1f7f51c1e1
commit
838b22aa19
@ -24,17 +24,24 @@
|
||||
*/
|
||||
package de.bluecolored.bluemap.core.storage;
|
||||
|
||||
import io.airlift.compress.zstd.ZstdInputStream;
|
||||
import io.airlift.compress.zstd.ZstdOutputStream;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.util.NoSuchElementException;
|
||||
import java.util.zip.DeflaterInputStream;
|
||||
import java.util.zip.DeflaterOutputStream;
|
||||
import java.util.zip.GZIPInputStream;
|
||||
import java.util.zip.GZIPOutputStream;
|
||||
|
||||
public enum Compression {
|
||||
|
||||
NONE("none", "", out -> out, in -> in),
|
||||
GZIP("gzip", ".gz", GZIPOutputStream::new, GZIPInputStream::new);
|
||||
GZIP("gzip", ".gz", GZIPOutputStream::new, GZIPInputStream::new),
|
||||
ZLIB("zlib", ".zlib", DeflaterOutputStream::new, DeflaterInputStream::new),
|
||||
ZSTD("zstd", ".zst", ZstdOutputStream::new, ZstdInputStream::new);
|
||||
|
||||
private final String typeId;
|
||||
private final String fileSuffix;
|
||||
|
Loading…
Reference in New Issue
Block a user