1 | |
---|
2 | <%@page import="net.sf.basedb.util.FileUtil"%> |
---|
3 | <%@page import="net.sf.basedb.util.StaticCache"%> |
---|
4 | <%@page import="net.sf.basedb.core.Application"%><%-- $Id: getFile.jsp 1132 2009-06-18 12:26:04Z nicklas $ |
---|
5 | ------------------------------------------------------------------ |
---|
6 | Copyright (C) 2009 Nicklas Nordborg |
---|
7 | |
---|
8 | This file is part of BASE - BioArray Software Environment. |
---|
9 | Available at http://base.thep.lu.se/ |
---|
10 | |
---|
11 | BASE is free software; you can redistribute it and/or |
---|
12 | modify it under the terms of the GNU General Public License |
---|
13 | as published by the Free Software Foundation; either version 2 |
---|
14 | of the License, or (at your option) any later version. |
---|
15 | |
---|
16 | BASE is distributed in the hope that it will be useful, |
---|
17 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
18 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
19 | GNU General Public License for more details. |
---|
20 | |
---|
21 | You should have received a copy of the GNU General Public License |
---|
22 | along with this program; if not, write to the Free Software |
---|
23 | Foundation, Inc., 59 Temple Place - Suite 330, |
---|
24 | Boston, MA 02111-1307, USA. |
---|
25 | ------------------------------------------------------------------ |
---|
26 | |
---|
27 | @author Jari, Nicklas |
---|
28 | --%> |
---|
29 | <%@ page |
---|
30 | pageEncoding="UTF-8" |
---|
31 | session="false" |
---|
32 | %> |
---|
33 | <% |
---|
34 | String file = request.getParameter("file"); |
---|
35 | String task = request.getParameter("task"); |
---|
36 | StaticCache cache = Application.getStaticCache(); |
---|
37 | response.resetBuffer(); |
---|
38 | String key = cache.makeValidKey("gp-integration/" + task + "/" + file, "-"); |
---|
39 | FileUtil.copy(cache.read(key, 1000), response.getOutputStream()); |
---|
40 | %> |
---|