code: public static String toHex(byte[] bytes) {
  		StringBuilder hexString=new StringBuilder();
  		for (int i=0; i<bytes.length; i++) {
  
  			String hex=Integer.toHexString(0xFF & bytes[i]);
  			if (hex.length() == 1) {
  				hexString.append('0');
  			}
  
  			hexString.append(hex);
  		}
  
  		return hexString.toString();
  	}
docs: Encode a byte array as a hexadecimal string
  
  @param	bytes
  @return