Class HttpResponse<T>
java.lang.Object
com.google.genai.gaos.utils.transport.HttpResponse<T>
An HTTP response that is independent of the underlying HTTP client.
The response body is an InputStream; callers are responsible for
consuming and closing it.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
HttpResponse
-
-
Method Details
-
request
Returns the request that produced this response. -
statusCode
public int statusCode() -
headers
Returns a copy of the response headers. Header names are case-insensitive. Mutating the returnedHeadersdoes not affect this response. -
contentType
Returns the value of the Content-Type header, if present. -
body
Returns the response body. Every call returns the same body instance; for one-shot bodies (streams) the caller is responsible for consuming it at most once and closing it where applicable. -
toString
-