How to get HttpServletRequest
开发者_运维知识库object in FlowController
?
I am trying to retrieve request object from getNativeRequest()
method,But it is not giving HttpServletRequest object.
(HttpServletRequest)RequestContextHolder.getRequestContext().getExternalContext().getNativeRequest()
I followed above approach, It's returning SRTServletRequest
object.
Correct me if I'm wrong, but SRTServletRequest
implements HttpServletRequest
, so you should just be able to cast it.
精彩评论