RequestUtil (Apache Tomcat 9.0.37 API Documentation)

org.apache.catalina.util

## Class RequestUtil

- java.lang.Object
- - org.apache.catalina.util.RequestUtil

-     public final class RequestUtil
      extends Object

  General purpose request parsing and encoding utility methods.
  Author:
    Craig R. McClanahan, Tim Tye

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `RequestUtil()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static StringBuffer` | `getRequestURL(HttpServletRequest request)` Build an appropriate return value for `HttpServletRequest.getRequestURL()` based on the provided request object.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### RequestUtil

          public RequestUtil()

  - ### Method Detail

    - #### getRequestURL

          public static StringBuffer getRequestURL(HttpServletRequest request)

      Build an appropriate return value for `HttpServletRequest.getRequestURL()` based on the provided request object. Note that this will also work for instances of `HttpServletRequestWrapper`.
      Parameters:
        `request` - The request object for which the URL should be built
      Returns:
        The request URL for the given request object

Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.