Here you can find the source of md5HashByteToString(byte[] bytes)
Parameter | Description |
---|---|
bytes | a parameter |
public static String md5HashByteToString(byte[] bytes)
//package com.java2s; //License from project: Open Source License public class Main { /**//from w w w.j av a 2 s .c o m * Creates an MD5 string from the given bytes. * * @param bytes * @return String value of the given bytes */ public static String md5HashByteToString(byte[] bytes) { String result = ""; for (int i = 0; i < bytes.length; i++) { result += Integer.toString((bytes[i] & 0xff) + 0x100, 16).substring(1); } return result; } }