Class HttpApiResponse
java.lang.Object
com.google.adk.network.ApiResponse
com.google.adk.network.HttpApiResponse
- All Implemented Interfaces:
AutoCloseable
Wraps a real HTTP response to expose the methods needed by the GenAI SDK.
-
Constructor Summary
ConstructorsConstructorDescriptionHttpApiResponse
(okhttp3.Response response) Constructs a HttpApiResponse instance with the response. -
Method Summary
-
Constructor Details
-
HttpApiResponse
public HttpApiResponse(okhttp3.Response response) Constructs a HttpApiResponse instance with the response.
-
-
Method Details
-
getEntity
public okhttp3.ResponseBody getEntity()Returns the ResponseBody from the response.- Specified by:
getEntity
in classApiResponse
-
close
public void close()Closes the Http response.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in classApiResponse
-