public static ServiceContext createServiceContext ( ServletRequest request ) { if ( ! ( request instanceof HttpServletRequest ) ) { throw new IllegalArgumentException ( "Expected HttpServletRequest" ) ; } return createServiceContext ( ( HttpServletRequest ) request ) ; }
Convenience method it requires that the request is a HttpServletRequest .