public interface ProxyResponse
Modifier and Type | Method and Description |
---|---|
ProxyResponse |
bodyFilter(java.util.function.Function<io.vertx.core.streams.ReadStream<io.vertx.core.buffer.Buffer>,io.vertx.core.streams.ReadStream<io.vertx.core.buffer.Buffer>> filter)
Set a body filter.
|
java.lang.String |
etag() |
Body |
getBody()
Get the body of the response.
|
int |
getStatusCode()
Get the status code.
|
java.lang.String |
getStatusMessage()
Get the status message.
|
io.vertx.core.MultiMap |
headers() |
long |
maxAge() |
boolean |
publicCacheControl() |
ProxyResponse |
putHeader(java.lang.CharSequence name,
java.lang.CharSequence value)
Put an HTTP header.
|
ProxyResponse |
release()
Release the proxy response.
|
ProxyRequest |
request()
Return the corresponding
ProxyRequest . |
io.vertx.core.Future<java.lang.Void> |
send()
Send the proxy response to the user agent.
|
ProxyResponse |
setBody(Body body)
Set the request body to be sent to the user agent.
|
ProxyResponse |
setStatusCode(int sc)
Set the status code to be sent to the user agent.
|
ProxyResponse |
setStatusMessage(java.lang.String statusMessage)
Set the status message to be sent to the user agent.
|
ProxyRequest request()
ProxyRequest
.int getStatusCode()
ProxyResponse setStatusCode(int sc)
The initial value is the inbound response status code.
sc
- the status codejava.lang.String getStatusMessage()
ProxyResponse setStatusMessage(java.lang.String statusMessage)
The initial value is the inbound response status message.
statusMessage
- the status messageio.vertx.core.MultiMap headers()
ProxyResponse putHeader(java.lang.CharSequence name, java.lang.CharSequence value)
name
- The header namevalue
- The header valueBody getBody()
ProxyResponse setBody(Body body)
The initial request body value is the outbound response body.
body
- the new bodyProxyResponse bodyFilter(java.util.function.Function<io.vertx.core.streams.ReadStream<io.vertx.core.buffer.Buffer>,io.vertx.core.streams.ReadStream<io.vertx.core.buffer.Buffer>> filter)
The body filter can rewrite the response body sent to the user agent.
filter
- the filterboolean publicCacheControl()
long maxAge()
java.lang.String etag()
etag
sent by the origin responseio.vertx.core.Future<java.lang.Void> send()
ProxyResponse release()
The HTTP client inbound response is resumed, no HTTP inbound server response is sent.
Copyright © 2023. All Rights Reserved.