Class CompressionSupport

java.lang.Object
io.lionweb.repoclient.CompressionSupport

public class CompressionSupport extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final okhttp3.MediaType
     
    static final okhttp3.MediaType
     
    static final okhttp3.MediaType
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static okhttp3.RequestBody
    compress(String content)
    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.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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

      public static okhttp3.RequestBody compress(String content)
      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.