- 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 Summary
Modifier and TypeFieldDescriptionstatic final String
The request attribute under a holder implementation is stored in the request -
Method Summary
Modifier and TypeMethodDescription<T extends jakarta.servlet.http.HttpServletRequest>
TGets the current HttpServletRequestvoid
setRequest
(jakarta.servlet.http.HttpServletRequest request) Sets the current HttpServletRequest
-
Field Details
-
CURRENT_REQUEST_ATTRIBUTE
The request attribute under a holder implementation is stored in the request
-
-
Method Details
-
getRequest
<T extends jakarta.servlet.http.HttpServletRequest> T getRequest()Gets the current HttpServletRequest- Type Parameters:
T
- the actual implementation of the current HttpServletRequest- Returns:
- the current HttpServletRequest
-
setRequest
void setRequest(jakarta.servlet.http.HttpServletRequest request) Sets the current HttpServletRequest- Parameters:
request
- the current HttpServletRequest
-