Class GzipRequestInterceptor
java.lang.Object
de.iip_ecosphere.platform.support.semanticId.eclass.handler.GzipRequestInterceptor
- All Implemented Interfaces:
com.squareup.okhttp.Interceptor
Encodes request bodies using gzip.
Taken from https://github.com/square/okhttp/issues/350
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.squareup.okhttp.Interceptor
com.squareup.okhttp.Interceptor.Chain -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate com.squareup.okhttp.RequestBodyforceContentLength(com.squareup.okhttp.RequestBody requestBody) private com.squareup.okhttp.RequestBodygzip(com.squareup.okhttp.RequestBody body) com.squareup.okhttp.Responseintercept(com.squareup.okhttp.Interceptor.Chain chain)
-
Constructor Details
-
GzipRequestInterceptor
GzipRequestInterceptor()
-
-
Method Details
-
intercept
public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException - Specified by:
interceptin interfacecom.squareup.okhttp.Interceptor- Throws:
IOException
-
forceContentLength
private com.squareup.okhttp.RequestBody forceContentLength(com.squareup.okhttp.RequestBody requestBody) throws IOException - Throws:
IOException
-
gzip
private com.squareup.okhttp.RequestBody gzip(com.squareup.okhttp.RequestBody body)
-