Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.platform.ui.web.download
Class DownloadServlet

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by org.nuxeo.ecm.platform.ui.web.download.DownloadServlet
All Implemented Interfaces:
Serializable, Servlet, ServletConfig

public class DownloadServlet
extends HttpServlet

Simple download servlet used for big files that can not be downloaded from within the JSF context (because of buffered ResponseWrapper).

Author:
tiry
See Also:
Serialized Form

Nested Class Summary
static class DownloadServlet.ByteRange
           
 
Constructor Summary
DownloadServlet()
           
 
Method Summary
 void handleClientDisconnect(IOException ioe)
           
static DownloadServlet.ByteRange parseRange(String range, int fileSize)
           
static void writeStream(InputStream in, OutputStream out, DownloadServlet.ByteRange range)
           
 
Methods inherited from class javax.servlet.http.HttpServlet
service
 
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DownloadServlet

public DownloadServlet()
Method Detail

handleClientDisconnect

public void handleClientDisconnect(IOException ioe)
                            throws IOException
Throws:
IOException

writeStream

public static void writeStream(InputStream in,
                               OutputStream out,
                               DownloadServlet.ByteRange range)
                        throws IOException
Throws:
IOException

parseRange

public static DownloadServlet.ByteRange parseRange(String range,
                                                   int fileSize)
                                            throws ClientException
Throws:
ClientException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.