DownloadBinaryServlet Class
- public class DownloadBinaryServlet
extends HttpServlet
-
Hierarchy
-
Object
GenericServlet
HttpServlet
DownloadBinaryServlet
-
All Implemented Interfaces
-
Serializable
, Servlet
, ServletConfig
Methods from javax.servlet.GenericServlet |
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log, service |
Methods from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DownloadBinaryServlet
public DownloadBinaryServlet()
doGet(HttpServletRequest, HttpServletResponse) Method
protected void doGet(HttpServletRequest
request,
HttpServletResponse
response)
throws ServletException
, IOException
-
Overrides
-
HttpServlet.doGet(HttpServletRequest, HttpServletResponse)
Exceptions
-
ServletException
-
IOException
downloadBinary(HttpServletRequest, HttpServletResponse) Method
protected void downloadBinary(HttpServletRequest
request,
HttpServletResponse
response)
throws ServletException
, RepositoryException
, IOException
Downloads the bytes of a binary property for a Node specified in the
request and provides a dialog box for users to save to their file system.
This will not print any error messages to the response.
Exceptions
-
ServletException
- thrown if there was an error processing the
request or response.
-
RepositoryException
- thrown on an error talking to the
repository or the Node doesn't have a content property to display.
-
IOException
- thrown on an error downloading and reading bytes.
showError(String, Throwable, HttpServletResponse) Method
protected void showError(String
error,
Throwable
ex,
HttpServletResponse
resp)
throws ServletException
, IOException
Exceptions
-
ServletException
-
IOException