Class Convert

java.lang.Object
tech.deplant.java4ever.utils.Convert

public class Convert extends Object
  • Constructor Details

    • Convert

      public Convert()
  • Method Details

    • base64ToHexString

      public static String base64ToHexString(String base64string)
    • longToDateTime

      public static LocalDateTime longToDateTime(long unixTime)
    • dateTimeToString

      public static String dateTimeToString(LocalDateTime dateTime)
    • decimalToString

      public static String decimalToString(BigDecimal decimalAmount, int scale)
    • hexToBigInt

      public static BigInteger hexToBigInt(String hexUint)
    • hexToDec

      public static BigDecimal hexToDec(String stringAmount, int scale)
    • hexToDecOrZero

      public static BigDecimal hexToDecOrZero(String stringAmount, int scale)
    • strToDec

      public static BigDecimal strToDec(String stringAmount, int scale)
    • strToHex

      public static String strToHex(String text)
      Utility method for preparing hex strings
      Parameters:
      text - Text string to encode.
      Returns:
      Hex string
    • hexToStr

      public static String hexToStr(String text)
    • padLeftZeros

      public static String padLeftZeros(String inputString, int length)