java.lang.Object
ee.jakarta.tck.ws.rs.common.webclient.Util

public class Util extends Object
  • Method Details

    • getBase64EncodedString

      public static String getBase64EncodedString(String value)
      BASE64 encodes the provided string.
      Returns:
      BASE64 encoded string.
    • getEncodedStringFromStream

      public static String getEncodedStringFromStream(InputStream in, String enc) throws IOException
      Returns a charset encoded string based on the provided InputStream and charset encoding.
      Returns:
      encoding string
      Throws:
      IOException
    • getHexValue

      public static String getHexValue(byte[] bytes, int pos, int len)
      getHexValue displays a formatted hex representation of the passed byte array. It also allows for only a specified offset and length of a particular array to be returned.
      Parameters:
      bytes - byte[] array to process.
      pos - int specifies offset to begin processing.
      len - int specifies the number of bytes to process.
      Returns:
      String formatted hex representation of processed array.