Android EventBus
Android 开发之如何优雅地复制Assets文件到SD卡
字节数组(byte[])转16进制字符串(HexString)
public static String bytesToHexString(byte[] bytes) { StringBuffer stringBuffer = new StringBuffer(); String temp = null; for (int i = 0; i < bytes.length; i++) { temp = Integer.toHexString(bytes[i] & 0xFF); if (temp.length() == 1) { stringBuffer.append("0"); } stringBuffer.append(temp); } return stringBuffer.toString().toUpperCase(); }
参考链接: