Class MockLiferayResourceResponse

Object
com.liferay.portal.kernel.test.portlet.MockLiferayResourceResponse
All Implemented Interfaces:
com.liferay.portal.kernel.portlet.LiferayPortletResponse, jakarta.portlet.MimeResponse, jakarta.portlet.PortletResponse, jakarta.portlet.ResourceResponse

public class MockLiferayResourceResponse extends Object implements com.liferay.portal.kernel.portlet.LiferayPortletResponse, jakarta.portlet.ResourceResponse
Author:
Cristina González
  • Constructor Details

    • MockLiferayResourceResponse

      public MockLiferayResourceResponse()
  • Method Details

    • addDateHeader

      public void addDateHeader(String name, long date)
      Specified by:
      addDateHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • addHeader

      public void addHeader(String name, String value)
      Specified by:
      addHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • addIntHeader

      public void addIntHeader(String name, int value)
      Specified by:
      addIntHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • addProperty

      public void addProperty(jakarta.servlet.http.Cookie cookie)
      Specified by:
      addProperty in interface jakarta.portlet.PortletResponse
    • addProperty

      public void addProperty(String name, Element element)
      Specified by:
      addProperty in interface jakarta.portlet.PortletResponse
    • addProperty

      public void addProperty(String name, String value)
      Specified by:
      addProperty in interface jakarta.portlet.PortletResponse
    • createActionURL

      public <T extends jakarta.portlet.PortletURL & jakarta.portlet.ActionURL> T createActionURL()
      Specified by:
      createActionURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
      Specified by:
      createActionURL in interface jakarta.portlet.MimeResponse
      Specified by:
      createActionURL in interface jakarta.portlet.ResourceResponse
    • createActionURL

      public jakarta.portlet.ActionURL createActionURL(jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createActionURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
      Specified by:
      createActionURL in interface jakarta.portlet.MimeResponse
      Specified by:
      createActionURL in interface jakarta.portlet.ResourceResponse
    • createActionURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createActionURL(String portletName)
      Specified by:
      createActionURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createActionURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createActionURL(String portletName, jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createActionURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createElement

      public Element createElement(String tagName) throws DOMException
      Specified by:
      createElement in interface jakarta.portlet.PortletResponse
      Throws:
      DOMException
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(long plid, String portletName, String lifecycle)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(long plid, String portletName, String lifecycle, boolean includeLinkToLayoutUuid)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(long plid, String portletName, String lifecycle, jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(long plid, String portletName, String lifecycle, jakarta.portlet.MimeResponse.Copy copy, boolean includeLinkToLayoutUuid)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(String lifecycle)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(String portletName, String lifecycle)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createLiferayPortletURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createLiferayPortletURL(String portletName, String lifecycle, jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createLiferayPortletURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createRenderURL

      public <T extends jakarta.portlet.PortletURL & jakarta.portlet.RenderURL> T createRenderURL()
      Specified by:
      createRenderURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
      Specified by:
      createRenderURL in interface jakarta.portlet.MimeResponse
      Specified by:
      createRenderURL in interface jakarta.portlet.ResourceResponse
    • createRenderURL

      public jakarta.portlet.RenderURL createRenderURL(jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createRenderURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
      Specified by:
      createRenderURL in interface jakarta.portlet.MimeResponse
      Specified by:
      createRenderURL in interface jakarta.portlet.ResourceResponse
    • createRenderURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createRenderURL(String portletName)
      Specified by:
      createRenderURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createRenderURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createRenderURL(String portletName, jakarta.portlet.MimeResponse.Copy copy)
      Specified by:
      createRenderURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • createResourceURL

      public jakarta.portlet.ResourceURL createResourceURL()
      Specified by:
      createResourceURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
      Specified by:
      createResourceURL in interface jakarta.portlet.MimeResponse
      Specified by:
      createResourceURL in interface jakarta.portlet.ResourceResponse
    • createResourceURL

      public com.liferay.portal.kernel.portlet.LiferayPortletURL createResourceURL(String portletName)
      Specified by:
      createResourceURL in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • encodeURL

      public String encodeURL(String url)
      Specified by:
      encodeURL in interface jakarta.portlet.PortletResponse
    • flushBuffer

      public void flushBuffer() throws IOException
      Specified by:
      flushBuffer in interface jakarta.portlet.MimeResponse
      Throws:
      IOException
    • getBufferSize

      public int getBufferSize()
      Specified by:
      getBufferSize in interface jakarta.portlet.MimeResponse
    • getCacheControl

      public jakarta.portlet.CacheControl getCacheControl()
      Specified by:
      getCacheControl in interface jakarta.portlet.MimeResponse
    • getCharacterEncoding

      public String getCharacterEncoding()
      Specified by:
      getCharacterEncoding in interface jakarta.portlet.MimeResponse
    • getContentType

      public String getContentType()
      Specified by:
      getContentType in interface jakarta.portlet.MimeResponse
    • getHttpServletResponse

      public jakarta.servlet.http.HttpServletResponse getHttpServletResponse()
      Specified by:
      getHttpServletResponse in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • getLifecycle

      public String getLifecycle()
      Specified by:
      getLifecycle in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • getLocale

      public Locale getLocale()
      Specified by:
      getLocale in interface jakarta.portlet.MimeResponse
    • getNamespace

      public String getNamespace()
      Specified by:
      getNamespace in interface jakarta.portlet.PortletResponse
    • getPortlet

      public com.liferay.portal.kernel.model.Portlet getPortlet()
      Specified by:
      getPortlet in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • getPortletOutputStream

      public OutputStream getPortletOutputStream() throws IOException
      Specified by:
      getPortletOutputStream in interface jakarta.portlet.MimeResponse
      Throws:
      IOException
    • getProperties

      public Map<String,String[]> getProperties()
      Specified by:
      getProperties in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • getProperty

      public String getProperty(String name)
      Specified by:
      getProperty in interface jakarta.portlet.PortletResponse
    • getPropertyNames

      public Collection<String> getPropertyNames()
      Specified by:
      getPropertyNames in interface jakarta.portlet.PortletResponse
    • getPropertyValues

      public Collection<String> getPropertyValues(String key)
      Specified by:
      getPropertyValues in interface jakarta.portlet.PortletResponse
    • getStatus

      public int getStatus()
      Specified by:
      getStatus in interface jakarta.portlet.ResourceResponse
    • getWriter

      public PrintWriter getWriter() throws IOException
      Specified by:
      getWriter in interface jakarta.portlet.MimeResponse
      Throws:
      IOException
    • isCommitted

      public boolean isCommitted()
      Specified by:
      isCommitted in interface jakarta.portlet.MimeResponse
    • reset

      public void reset()
      Specified by:
      reset in interface jakarta.portlet.MimeResponse
    • resetBuffer

      public void resetBuffer()
      Specified by:
      resetBuffer in interface jakarta.portlet.MimeResponse
    • setBufferSize

      public void setBufferSize(int bufferSize)
      Specified by:
      setBufferSize in interface jakarta.portlet.MimeResponse
    • setCharacterEncoding

      public void setCharacterEncoding(String characterEncoding)
      Specified by:
      setCharacterEncoding in interface jakarta.portlet.ResourceResponse
    • setContentLength

      public void setContentLength(int contentLength)
      Specified by:
      setContentLength in interface jakarta.portlet.ResourceResponse
    • setContentLengthLong

      public void setContentLengthLong(long contentLength)
      Specified by:
      setContentLengthLong in interface jakarta.portlet.ResourceResponse
    • setContentType

      public void setContentType(String contentType)
      Specified by:
      setContentType in interface jakarta.portlet.MimeResponse
    • setDateHeader

      public void setDateHeader(String name, long date)
      Specified by:
      setDateHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • setHeader

      public void setHeader(String name, String value)
      Specified by:
      setHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • setIntHeader

      public void setIntHeader(String name, int value)
      Specified by:
      setIntHeader in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • setLocale

      public void setLocale(Locale locale)
      Specified by:
      setLocale in interface jakarta.portlet.ResourceResponse
    • setProperty

      public void setProperty(String property, String value)
      Specified by:
      setProperty in interface jakarta.portlet.PortletResponse
    • setStatus

      public void setStatus(int status)
      Specified by:
      setStatus in interface jakarta.portlet.ResourceResponse
    • setURLEncoder

      public void setURLEncoder(com.liferay.portal.kernel.servlet.URLEncoder urlEncoder)
      Specified by:
      setURLEncoder in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • transferHeaders

      public void transferHeaders(jakarta.servlet.http.HttpServletResponse httpServletResponse)
      Specified by:
      transferHeaders in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse
    • transferMarkupHeadElements

      public void transferMarkupHeadElements()
      Specified by:
      transferMarkupHeadElements in interface com.liferay.portal.kernel.portlet.LiferayPortletResponse