public class OwRenditionServlet
extends javax.servlet.http.HttpServlet
OwRenditionServlet for retrieval of renditions from objects.
Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.
For licensing information read the license.txt file or
go to: http://wiki.alfresco.com
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_PARAM_FALLBACK |
static String |
DEFAULT_PARAM_RENDITION |
Constructor and Description |
---|
OwRenditionServlet() |
Modifier and Type | Method and Description |
---|---|
protected void |
doGet(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp) |
protected void |
doPost(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp) |
protected String |
getConfiguredImage(javax.servlet.ServletConfig config,
String initParam)
Helper to get configured path to images.
|
protected OwObject |
getRequestedObject(javax.servlet.http.HttpServletRequest req,
OwAppContext context)
Retrieve the object from request.
|
protected void |
handleNoRendition(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
OwObject obj,
OwRenditionServiceProvider prov,
String type)
(overridable)
Called in case no Rendition service could be found.
|
void |
init(javax.servlet.ServletConfig config) |
protected void |
process(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp) |
protected boolean |
sendRendition(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
OwRenditionServiceProvider prov,
OwRenditionService service,
OwObject obj,
String renditionType) |
protected void |
showStaticImage(javax.servlet.http.HttpServletResponse resp,
String path)
Show a static image from provided path.
|
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
public static final String DEFAULT_PARAM_RENDITION
public static final String DEFAULT_PARAM_FALLBACK
public void init(javax.servlet.ServletConfig config) throws javax.servlet.ServletException
init
in interface javax.servlet.Servlet
init
in class javax.servlet.GenericServlet
javax.servlet.ServletException
protected String getConfiguredImage(javax.servlet.ServletConfig config, String initParam)
config
- ServletConfiginitParam
- Stringprotected void doGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void doPost(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doPost
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
protected void process(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
javax.servlet.ServletException
IOException
protected void handleNoRendition(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, OwObject obj, OwRenditionServiceProvider prov, String type) throws OwException, IOException
req
- HttpServletRequestresp
- HttpServletResponseobj
- prov
- IOException
OwException
protected void showStaticImage(javax.servlet.http.HttpServletResponse resp, String path) throws IOException
resp
- HttpServletResponsepath
- String path to imageIOException
protected OwObject getRequestedObject(javax.servlet.http.HttpServletRequest req, OwAppContext context) throws OwException
req
- HttpServletRequestcontext
- OwAppContextOwException
- if object cannot be retrieved from provided requestprotected boolean sendRendition(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, OwRenditionServiceProvider prov, OwRenditionService service, OwObject obj, String renditionType) throws IOException, OwException
IOException
OwException
Copyright © 2014 Alfresco Business Solutions. All Rights Reserved.