爪哇代码
@RequestMapping('/getVideo')
public void loadVideo(HttpServletHttp req, HttpServletResponse response) throws {
Integer id = request.getParameter("fileId");
String path = resourceService.getFilePath(id);
File file = new File(path);
/**how to deal with video for Output stream to html5 tag video play*/
}
jsp代码
<video src="getVideo.do?fileId=xxxx" type="video/mp4">
如何编程,或其他想法?