Interface CurrentRequestHolder

  • All Known Implementing Classes:
    DefaultCurrentRequestHolder

    public interface CurrentRequestHolder
    A holder that references the current HttpServletRequest in the request processing pipeline.

    This structure allows the runtime to set what constitutes this current at any given time.

    Author:
    Arjan Tijms
    • Field Detail

      • CURRENT_REQUEST_ATTRIBUTE

        static final String CURRENT_REQUEST_ATTRIBUTE
        The request attribute under a holder implementation is stored in the request
    • Method Detail

      • getRequest

        <T extends HttpServletRequest> T getRequest()
        Gets the current HttpServletRequest
        Type Parameters:
        T - the actual implementation of the current HttpServletRequest
        Returns:
        the current HttpServletRequest
      • setRequest

        void setRequest​(HttpServletRequest request)
        Sets the current HttpServletRequest
        Parameters:
        request - the current HttpServletRequest