Interface OutboundResponseHeaders

All Superinterfaces:
InboundHeaders, InboundResponseHeaders, OutboundHeaders<OutboundResponseHeaders>

public interface OutboundResponseHeaders extends InboundResponseHeaders, OutboundHeaders<OutboundResponseHeaders>

Represents mutable outbound HTTP response headers.

This extends the OutboundHeaders to expose response specific information like response status, content type, content length and set-cookies.

An outbound response is sent by a server in a server exchange.

Since:
1.6
Author:
Jeremy Kuhn
  • Method Details

    • status

      Sets the response HTTP status.

      Parameters:
      status - the HTTP status
      Returns:
      the response headers
    • status

      OutboundResponseHeaders status(int status)

      Sets the response HTTP status code

      Parameters:
      status - the HTTP status code
      Returns:
      the response headers
    • contentType

      OutboundResponseHeaders contentType(String contentType)

      Sets the response content type header field value.

      Parameters:
      contentType - the content type
      Returns:
      the response headers
    • contentLength

      OutboundResponseHeaders contentLength(long contentLength)

      Sets the response content length.

      Parameters:
      contentLength - the content length
      Returns:
      the response headers
    • cookies

      Sets the response set-cookies.

      Parameters:
      cookiesConfigurer - an outbound set-cookies configurer
      Returns:
      the response headers