Class IOUtil

java.lang.Object
com.targomo.client.api.util.IOUtil

public final class IOUtil extends Object
  • Method Details

    • cloneObjects

      public static <T> T cloneObjects(T object, Class<T> clazz)
      Deep cloning of an POJO object.
      Type Parameters:
      T - type of the object
      Parameters:
      object - input object
      clazz - specified object class
      Returns:
      clone of the object
    • decode

      public static String decode(String string)
      Decode a URL-encoded String
      Parameters:
      string - URL-encoded string
      Returns:
      Decoded string
    • encode

      public static String encode(String string)
      Convert a String to URL-encoded version
      Parameters:
      string - input String
      Returns:
      URL-encoded version of string
    • getResultString

      public static String getResultString(javax.ws.rs.core.Response response)
      Convert get body from HTTP response and remove callback field
      Parameters:
      response - HTTP response
      Returns:
      Response body without callback