commons-fileupload 多文件上传
第三方的文件上传工具类,例如这个东东:http://www.oschina.net/p/commons-fileupload,解析的方法无非就是这样:
1:在 controller 中先 HttpServletRequest request = getRequest();
2:将 request 传入第三方的组件
DiskFileItemFactory factory = new DiskFileItemFactory();
ServletFileUpload upload = new ServletFileUpload(factory);
List items = upload.parseRequest(request);
3:迭代解析出文件内容