public final class MongoCompressor
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
LEVEL
The property key for defining the compression level.
|
| Modifier and Type | Method and Description |
|---|---|
static MongoCompressor |
createSnappyCompressor()
Create an instance for snappy compression.
|
static MongoCompressor |
createZlibCompressor()
Create an instance for zlib compression.
|
static MongoCompressor |
createZstdCompressor()
Create an instance for zstd compression.
|
boolean |
equals(java.lang.Object o) |
java.lang.String |
getName()
Gets the name of the compressor.
|
<T> T |
getProperty(java.lang.String key,
T defaultValue)
Gets the property with the given key.
|
<T> T |
getPropertyNonNull(java.lang.String key,
T defaultValue)
Gets the property with the given key.
|
int |
hashCode() |
java.lang.String |
toString() |
<T> MongoCompressor |
withProperty(java.lang.String key,
T value)
Creates a new compressor from this compressor with the given property added to it.
|
public static final java.lang.String LEVEL
public static MongoCompressor createSnappyCompressor()
public static MongoCompressor createZlibCompressor()
public static MongoCompressor createZstdCompressor()
public java.lang.String getName()
@Nullable
public <T> T getProperty(java.lang.String key,
T defaultValue)
T - the property value typekey - the keydefaultValue - the default valuepublic <T> T getPropertyNonNull(java.lang.String key,
T defaultValue)
T - the property value typekey - the keydefaultValue - the default valuejava.lang.IllegalArgumentException - if the value and default value are nullpublic <T> MongoCompressor withProperty(java.lang.String key, T value)
T - the property value typekey - the property keyvalue - the property valuepublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2010 - 2023 Adobe. All Rights Reserved