类 HashUtils
- java.lang.Object
-
- com.baidubce.util.HashUtils
-
public class HashUtils extends Object
Utility methods for computing MD5 sums.
-
-
构造器概要
构造器 构造器 说明 HashUtils()
-
方法概要
所有方法 静态方法 具体方法 修饰符和类型 方法 说明 static byte[]computeHash(InputStream is, MessageDigest messageDigest)static byte[]computeMd5Hash(InputStream is)Computes the MD5 hash of the data in the given input stream and returns it as an array of bytes.static byte[]computeSha256Hash(InputStream is)
-
-
-
方法详细资料
-
computeMd5Hash
public static byte[] computeMd5Hash(InputStream is) throws NoSuchAlgorithmException, IOException
Computes the MD5 hash of the data in the given input stream and returns it as an array of bytes.
-
computeSha256Hash
public static byte[] computeSha256Hash(InputStream is) throws NoSuchAlgorithmException, IOException
-
computeHash
public static byte[] computeHash(InputStream is, MessageDigest messageDigest) throws IOException
- 抛出:
IOException
-
-