org.springframework.http.server.reactive

## Interface ServerHttpRequest

- All Superinterfaces:
    HttpMessage, HttpRequest, ReactiveHttpInputMessage
  All Known Implementing Classes:
    AbstractServerHttpRequest, MockServerHttpRequest, ServerHttpRequestDecorator

      public interface ServerHttpRequest
      extends HttpRequest, ReactiveHttpInputMessage

  Represents a reactive server-side HTTP request.
  Since:
    5.0
  Author:
    Arjen Poutsma, Rossen Stoyanchev, Sam Brannen

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `ServerHttpRequest.Builder` Builder for mutating an existing `ServerHttpRequest`.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `MultiValueMap<String,HttpCookie>` | `getCookies()` Return a read-only map of cookies sent by the client.
    `String` | `getId()` Return an id that represents the underlying connection, if available, or the request for the purpose of correlating log messages.
    `default InetSocketAddress` | `getLocalAddress()` Return the local address the request was accepted on, if available.
    `RequestPath` | `getPath()` Returns a structured representation of the full request path up to but not including the `query`.
    `MultiValueMap<String,String>` | `getQueryParams()` Return a read-only map with parsed and decoded query parameter values.
    `default InetSocketAddress` | `getRemoteAddress()` Return the remote address where this request is connected to, if available.
    `default SslInfo` | `getSslInfo()` Return the SSL session information if the request has been transmitted over a secure protocol including SSL certificates, if available.
    `default ServerHttpRequest.Builder` | `mutate()` Return a builder to mutate properties of this request by wrapping it with `ServerHttpRequestDecorator` and returning either mutated values or delegating back to this instance.

    - ### Methods inherited from interface org.springframework.http.HttpRequest

      `getMethod, getMethodValue, getURI`

    - ### Methods inherited from interface org.springframework.http.ReactiveHttpInputMessage

      `getBody`

    - ### Methods inherited from interface org.springframework.http.HttpMessage

      `getHeaders`

- - ### Method Detail

    - #### getId

          String getId()

      Return an id that represents the underlying connection, if available, or the request for the purpose of correlating log messages.
      Since:
        5.1
      See Also:
        `ServerWebExchange.getLogPrefix()`

    - #### getPath

          RequestPath getPath()

      Returns a structured representation of the full request path up to but not including the `query`.

      The returned path is subdivided into a `RequestPath.contextPath()` portion and the remaining `pathWithinApplication` portion. The latter can be passed into methods of `PathPattern` for path matching purposes.

    - #### getQueryParams

          MultiValueMap<String,String> getQueryParams()

      Return a read-only map with parsed and decoded query parameter values.

    - #### getCookies

          MultiValueMap<String,HttpCookie> getCookies()

      Return a read-only map of cookies sent by the client.

    - #### getLocalAddress

          @Nullable
          default InetSocketAddress getLocalAddress()

      Return the local address the request was accepted on, if available.
      Since:
        5.2.3

    - #### getRemoteAddress

          @Nullable
          default InetSocketAddress getRemoteAddress()

      Return the remote address where this request is connected to, if available.

    - #### getSslInfo

          @Nullable
          default SslInfo getSslInfo()

      Return the SSL session information if the request has been transmitted over a secure protocol including SSL certificates, if available.
      Returns:
        the session information, or `null` if none available
      Since:
        5.0.2

    - #### mutate

          default ServerHttpRequest.Builder mutate()

      Return a builder to mutate properties of this request by wrapping it with `ServerHttpRequestDecorator` and returning either mutated values or delegating back to this instance.