java.lang.Object
net.finmath.smartcontracts.representablestate.xml.util.Util

public class Util extends Object
Utilities related to encryption/decryption/hashing
Author:
Christian Fries
  • Method Details

    • getHex

      public static String getHex(byte[] bytes)
      Get a Hex representation of the byte-array.
      Parameters:
      bytes - an array of byte
      Returns:
      a String object representing the byte array in hex.
    • getHexTrimmed

      public static String getHexTrimmed(byte[] bytes)
      Get the first hex values of the byte-array (e.g. for logging).
      Parameters:
      bytes - an array of byte
      Returns:
      a String object representing the byte array in base64.
    • getHexTrimmed

      public static String getHexTrimmed(byte[] bytes, int len)
      Get the first hex values of the byte-array (e.g. for logging).
      Parameters:
      bytes - an array of byte
      len - the length to represent
      Returns:
      a String object with starting hex encodings of the byte array.
    • getBase64

      public static String getBase64(byte[] bytes)
      Get a Base64 representation of the byte-array.
      Parameters:
      bytes - an array of byte
      Returns:
      a String object