Class DUUICompressionHelper
java.lang.Object
org.texttechnologylab.DockerUnifiedUIMAInterface.DUUICompressionHelper
Helper class for compression and decompression of strings.
-
Constructor Summary
ConstructorDescriptionDUUICompressionHelper
(String method) Constructor using aCompressorStreamFactory
and a compression method. -
Method Summary
Modifier and TypeMethodDescriptionCompresses a string.decompress
(String input) Decompresses a string.
-
Constructor Details
-
DUUICompressionHelper
Constructor using aCompressorStreamFactory
and a compression method.- Parameters:
method
-
-
-
Method Details
-
compress
public String compress(String input) throws IOException, org.apache.commons.compress.compressors.CompressorException Compresses a string.- Parameters:
input
- The string to compress.- Returns:
- The compressed string as a base64 encoded string.
- Throws:
IOException
org.apache.commons.compress.compressors.CompressorException
-
decompress
public String decompress(String input) throws IOException, org.apache.commons.compress.compressors.CompressorException Decompresses a string.- Parameters:
input
- The compressed string as a base64 encoded string.- Returns:
- The decompressed string.
- Throws:
IOException
org.apache.commons.compress.compressors.CompressorException
-
getCompressionMethod
-