code: public static byte[] fromHex(String hex) {
          try {
              return Hex.decodeHex(hex.toCharArray());
          } catch (DecoderException e) {
              return null;
          }
      }
docs: recreate a byte array from hexadecimal
  
  @param hex
  string data
  @return byte[] data