Package io.lionweb.repoclient
Class CompressionSupport
java.lang.Object
io.lionweb.repoclient.CompressionSupport
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final okhttp3.MediaType
static final okhttp3.MediaType
static final okhttp3.MediaType
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic okhttp3.RequestBody
Converts a String to a compressed RequestBody using JSON MediaType.static okhttp3.RequestBody
compress
(okhttp3.RequestBody body) Compresses a given RequestBody using GZIP and ensures the content length is known.
-
Field Details
-
JSON
public static final okhttp3.MediaType JSON -
PROTOBUF
public static final okhttp3.MediaType PROTOBUF -
FLATBUFFERS
public static final okhttp3.MediaType FLATBUFFERS
-
-
Constructor Details
-
CompressionSupport
public CompressionSupport()
-
-
Method Details
-
compress
Converts a String to a compressed RequestBody using JSON MediaType. -
compress
public static okhttp3.RequestBody compress(okhttp3.RequestBody body) Compresses a given RequestBody using GZIP and ensures the content length is known.
-