Class Base64Util

java.lang.Object
com.luna.common.encrypt.Base64Util

public class Base64Util extends Object
Author:
Luna@win10
  • Constructor Details

    • Base64Util

      public Base64Util()
  • Method Details

    • encodeBase64

      public static String encodeBase64(byte[] from)
      Base64 encoding.
      Parameters:
      from - The src data.
      Returns:
      cryto_str
    • decodeBase64

      public static byte[] decodeBase64(String s)
      Translates the specified Base64 string into a byte array.
      Parameters:
      s - the Base64 string (not null)
      Returns:
      the byte array (not null)
    • imageSize

      public static Integer imageSize(String image)
      通过图片base64流判断图片等于多少字节 image 图片流
    • isBase64

      public static boolean isBase64(String str)
      检测是否为base64编码
      Parameters:
      str -
      Returns: