把你读的encode一下不就完事了吗
解决方案 »
- java 时间离现在若干小时时刻的代码怎么会有时候对有时候错呢?
- 从数据库中一次取出多幅图片并显示在同一个jsp页面中
- spring发送邮件问题
- 请问怎么用eclipse搭建SSH框架
- 你见过这样的问题吗(??)
- ECLPSI安装问题
- java实现linux的ping命令问题
- axis在tomcat中正常工作,在weblogic8.1中工作不正常。真惊了!!WHY??????????????
- 该杀的日本鬼
- 在struts 的action 中我怎么使用mapping.findforward后new ActionForward()来是我的return的jsp界面在新的一业中显示啊????????急!!!!看
- JUnit 对 SSH 中 Service的测试
- post提交上传文件后变成了get提交
String result = null;
File file = new File(filePath);
try {
FileInputStream fis = new FileInputStream(file);
WordExtractor wordExtractor = new WordExtractor(fis);
result = wordExtractor.getText();
/*base64加密*/
System.out.println(new BASE64Encoder()).encodeBuffer(result));
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
;
return result;
}
System.out.println(new BASE64Decoder()).decodeBuffer(result));
没处理过图片,你可以将图片以二进制流的方式放到xml,在解析这段xml。
用到java FileStream类,具体怎么用你上网查下