Interface IServletRequest300To310Migration

  • All Superinterfaces:
    jakarta.servlet.ServletRequest

    public interface IServletRequest300To310Migration
    extends jakarta.servlet.ServletRequest
    Dummy interface with all ServletRequest default methods for new methods in Servlet Spec 3.1.0 compared to 3.0.0
    Author:
    Philip Helger
    • Method Summary

      All Methods Instance Methods Default Methods 
      Modifier and Type Method Description
      default long getContentLengthLong()
      Returns the length, in bytes, of the request body and made available by the input stream, or -1 if the length is not known.
      • Methods inherited from interface jakarta.servlet.ServletRequest

        getAsyncContext, getAttribute, getAttributeNames, getCharacterEncoding, getContentLength, getContentType, getDispatcherType, getInputStream, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getParameter, getParameterMap, getParameterNames, getParameterValues, getProtocol, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRequestDispatcher, getScheme, getServerName, getServerPort, getServletContext, isAsyncStarted, isAsyncSupported, isSecure, removeAttribute, setAttribute, setCharacterEncoding, startAsync, startAsync
    • Method Detail

      • getContentLengthLong

        default long getContentLengthLong()
        Returns the length, in bytes, of the request body and made available by the input stream, or -1 if the length is not known. For HTTP servlets, same as the value of the CGI variable CONTENT_LENGTH.
        Specified by:
        getContentLengthLong in interface jakarta.servlet.ServletRequest
        Returns:
        a long containing the length of the request body or -1L if the length is not known
        Since:
        Servlet 3.1