code: public static ServletHttpRequest unwrap(ServletRequest request)
      {
          while (!(request instanceof ServletHttpRequest))
          {
              if (request instanceof ServletRequestWrapper)
              {
                  ServletRequestWrapper wrapper =
                      (ServletRequestWrapper)request;
                  request=wrapper.getRequest();
              }
              else
                  throw new IllegalArgumentException("Does not wrap ServletHttpRequest");
          }
  
          return (ServletHttpRequest)request;
      }
docs: Unwrap a ServletRequest.
  
  @see javax.servlet.ServletRequestWrapper
  @see javax.servlet.http.HttpServletRequestWrapper
  @param request
  @return The core ServletHttpRequest which must be the
  underlying request object