Package com.liferay.portal.webserver
Class WebServerServlet
Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
com.liferay.portal.webserver.WebServerServlet
- All Implemented Interfaces:
Serializable,javax.servlet.Servlet,javax.servlet.ServletConfig
public class WebServerServlet
extends javax.servlet.http.HttpServlet
- Author:
- Alexander Chow, Brian Wing Shun Chan
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected com.liferay.portal.kernel.model.ImageconvertFileEntry(boolean smallImage, com.liferay.portal.kernel.repository.model.FileEntry fileEntry) protected com.liferay.portal.kernel.model.ImagegetDefaultImage(javax.servlet.http.HttpServletRequest httpServletRequest, long imageId) protected com.liferay.portal.kernel.model.ImagegetImage(javax.servlet.http.HttpServletRequest httpServletRequest, boolean getDefault) protected byte[]getImageBytes(javax.servlet.http.HttpServletRequest httpServletRequest, com.liferay.portal.kernel.model.Image image) protected longgetImageId(javax.servlet.http.HttpServletRequest httpServletRequest) protected longgetLastModified(javax.servlet.http.HttpServletRequest httpServletRequest) protected static com.liferay.portal.kernel.repository.model.FileEntrygetPortletFileEntry(javax.servlet.http.HttpServletRequest httpServletRequest, String[] pathArray) protected com.liferay.portal.kernel.model.ImagegetUserPortraitImageResized(com.liferay.portal.kernel.model.Image image, long imageId) static booleanhasFiles(javax.servlet.http.HttpServletRequest httpServletRequest) voidinit(javax.servlet.ServletConfig servletConfig) protected booleanisLegacyImageGalleryImageId(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) protected booleanisSupportsRangeHeader(String contentType) protected voidprocessPrincipalException(Throwable throwable, com.liferay.portal.kernel.model.User user, javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) protected voidsendDocumentLibrary(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String path, String[] pathArray) protected voidsendFile(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String[] pathArray) protected voidsendFile(javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, long groupId, long folderId, String title) protected voidsendGroups(javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String path) protected voidsendHTML(javax.servlet.http.HttpServletResponse httpServletResponse, String path, List<WebServerEntry> webServerEntries) static voidsendMessageObjectEntryAttachmentDownload(javax.servlet.http.HttpServletRequest httpServletRequest, com.liferay.portal.kernel.model.User user) protected voidsendPortletFileEntry(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, String path, String[] pathArray) voidservice(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) protected voidwriteImage(com.liferay.portal.kernel.model.Image image, javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doGet, doHead, doOptions, doPost, doPut, doTrace, serviceMethods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
-
Field Details
-
PATH_PORTLET_FILE_ENTRY
- See Also:
-
-
Constructor Details
-
WebServerServlet
public WebServerServlet()
-
-
Method Details
-
hasFiles
public static boolean hasFiles(javax.servlet.http.HttpServletRequest httpServletRequest) - See Also:
-
sendMessageObjectEntryAttachmentDownload
public static void sendMessageObjectEntryAttachmentDownload(javax.servlet.http.HttpServletRequest httpServletRequest, com.liferay.portal.kernel.model.User user) - See Also:
-
init
public void init(javax.servlet.ServletConfig servletConfig) throws javax.servlet.ServletException - Specified by:
initin interfacejavax.servlet.Servlet- Overrides:
initin classjavax.servlet.GenericServlet- Throws:
javax.servlet.ServletException
-
service
public void service(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) throws IOException, javax.servlet.ServletException - Overrides:
servicein classjavax.servlet.http.HttpServlet- Throws:
IOExceptionjavax.servlet.ServletException
-
getPortletFileEntry
protected static com.liferay.portal.kernel.repository.model.FileEntry getPortletFileEntry(javax.servlet.http.HttpServletRequest httpServletRequest, String[] pathArray) throws Exception - Throws:
Exception
-
convertFileEntry
protected com.liferay.portal.kernel.model.Image convertFileEntry(boolean smallImage, com.liferay.portal.kernel.repository.model.FileEntry fileEntry) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
getDefaultImage
protected com.liferay.portal.kernel.model.Image getDefaultImage(javax.servlet.http.HttpServletRequest httpServletRequest, long imageId) -
getImage
protected com.liferay.portal.kernel.model.Image getImage(javax.servlet.http.HttpServletRequest httpServletRequest, boolean getDefault) throws Exception - Throws:
Exception
-
getImageBytes
protected byte[] getImageBytes(javax.servlet.http.HttpServletRequest httpServletRequest, com.liferay.portal.kernel.model.Image image) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
getImageId
protected long getImageId(javax.servlet.http.HttpServletRequest httpServletRequest) -
getLastModified
protected long getLastModified(javax.servlet.http.HttpServletRequest httpServletRequest) - Overrides:
getLastModifiedin classjavax.servlet.http.HttpServlet
-
getUserPortraitImageResized
protected com.liferay.portal.kernel.model.Image getUserPortraitImageResized(com.liferay.portal.kernel.model.Image image, long imageId) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
isLegacyImageGalleryImageId
protected boolean isLegacyImageGalleryImageId(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) -
isSupportsRangeHeader
-
processPrincipalException
protected void processPrincipalException(Throwable throwable, com.liferay.portal.kernel.model.User user, javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) throws IOException, javax.servlet.ServletException - Throws:
IOExceptionjavax.servlet.ServletException
-
sendDocumentLibrary
protected void sendDocumentLibrary(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String path, String[] pathArray) throws Exception - Throws:
Exception
-
sendFile
protected void sendFile(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String[] pathArray) throws Exception - Throws:
Exception
-
sendFile
protected void sendFile(javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, long groupId, long folderId, String title) throws Exception - Throws:
Exception
-
sendGroups
protected void sendGroups(javax.servlet.http.HttpServletResponse httpServletResponse, com.liferay.portal.kernel.model.User user, String path) throws Exception - Throws:
Exception
-
sendHTML
protected void sendHTML(javax.servlet.http.HttpServletResponse httpServletResponse, String path, List<WebServerEntry> webServerEntries) throws Exception - Throws:
Exception
-
sendPortletFileEntry
protected void sendPortletFileEntry(javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse, String path, String[] pathArray) throws Exception - Throws:
Exception
-
writeImage
protected void writeImage(com.liferay.portal.kernel.model.Image image, javax.servlet.http.HttpServletRequest httpServletRequest, javax.servlet.http.HttpServletResponse httpServletResponse) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-