use of jakarta.servlet.ServletRequest in project spring-framework by spring-projects.
the class AbstractDataBoundFormElementTag method processFieldValue.
/**
* Process the given form field through a {@link RequestDataValueProcessor}
* instance if one is configured or otherwise returns the same value.
*/
protected final String processFieldValue(@Nullable String name, String value, String type) {
RequestDataValueProcessor processor = getRequestContext().getRequestDataValueProcessor();
ServletRequest request = this.pageContext.getRequest();
if (processor != null && request instanceof HttpServletRequest) {
value = processor.processFormFieldValue((HttpServletRequest) request, name, value, type);
}
return value;
}
use of jakarta.servlet.ServletRequest in project spring-framework by spring-projects.
the class AbstractHttpSockJsSession method disableShallowEtagHeaderFilter.
private void disableShallowEtagHeaderFilter(ServerHttpRequest request) {
if (request instanceof ServletServerHttpRequest) {
ServletRequest servletRequest = ((ServletServerHttpRequest) request).getServletRequest();
ShallowEtagHeaderFilter.disableContentCaching(servletRequest);
}
}
use of jakarta.servlet.ServletRequest in project spring-framework by spring-projects.
the class ServletRequestMethodArgumentResolverTests method setup.
@BeforeEach
public void setup() throws Exception {
resolver = new ServletRequestMethodArgumentResolver();
mavContainer = new ModelAndViewContainer();
servletRequest = new MockHttpServletRequest("GET", "");
webRequest = new ServletWebRequest(servletRequest, new MockHttpServletResponse());
method = getClass().getMethod("supportedParams", ServletRequest.class, MultipartRequest.class, HttpSession.class, Principal.class, Locale.class, InputStream.class, Reader.class, WebRequest.class, TimeZone.class, ZoneId.class, HttpMethod.class, PushBuilder.class);
}
Aggregations