Package com.bc.zarr
Class CompressorFactory
- java.lang.Object
-
- com.bc.zarr.CompressorFactory
-
public class CompressorFactory extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCompressorFactory.BloscCompressor
-
Field Summary
Fields Modifier and Type Field Description static CompressornullCompressor
-
Constructor Summary
Constructors Constructor Description CompressorFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Compressorcreate(String id, Object... keyValuePair)Creates a newCompressorinstance according to the id and the given properties.static Compressorcreate(String id, Map<String,Object> properties)Creates a newCompressorinstance according to the id and the given properties.static Compressorcreate(Map<String,Object> properties)Creates a newCompressorinstance according to the given properties.static CompressorcreateDefaultCompressor()static Map<String,Object>getDefaultCompressorProperties()
-
-
-
Field Detail
-
nullCompressor
public static final Compressor nullCompressor
-
-
Method Detail
-
getDefaultCompressorProperties
public static Map<String,Object> getDefaultCompressorProperties()
- Returns:
- the properties of the default compressor as a key/value map.
-
createDefaultCompressor
public static Compressor createDefaultCompressor()
- Returns:
- a new Compressor instance using the method
create(Map properties)withgetDefaultCompressorProperties().
-
create
public static Compressor create(Map<String,Object> properties)
Creates a newCompressorinstance according to the given properties.- Parameters:
properties- a Map containing the properties to create a compressor- Returns:
- a new Compressor instance according to the properties
- Throws:
IllegalArgumentException- If it is not able to create a Compressor.
-
create
public static Compressor create(String id, Object... keyValuePair)
Creates a newCompressorinstance according to the id and the given properties.- Parameters:
id- the type of the compression algorithmkeyValuePair- an even count of key value pairs defining the compressor specific properties- Returns:
- a new Compressor instance according to the id and the properties
- Throws:
IllegalArgumentException- If it is not able to create a Compressor.
-
create
public static Compressor create(String id, Map<String,Object> properties)
Creates a newCompressorinstance according to the id and the given properties.- Parameters:
id- the type of the compression algorithmproperties- a Map containing the compressor specific properties- Returns:
- a new Compressor instance according to the id and the properties
- Throws:
IllegalArgumentException- If it is not able to create a Compressor.
-
-