赞
踩
write.close();
2、转为base64
FileInputStream read = new FileInputStream(new File("d://a.jpg"));
byte[] buffer = new byte[read.available()];
read.read(buffer);
byte[] bytes = org.apache.commons.codec.binary.Base64.encodeBase64(buffer);
System.out.println(new String(bytes));
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。