Class HttpOptions.Builder
-
- All Implemented Interfaces:
public abstract class HttpOptions.BuilderBuilder for HttpOptions.
-
-
Constructor Summary
Constructors Constructor Description HttpOptions.Builder()
-
Method Summary
Modifier and Type Method Description abstract HttpOptions.BuilderbaseUrl(String baseUrl)Setter for baseUrl. HttpOptions.BuilderclearBaseUrl()Clears the value of baseUrl field. abstract HttpOptions.BuilderbaseUrlResourceScope(ResourceScope baseUrlResourceScope)Setter for baseUrlResourceScope. HttpOptions.BuilderclearBaseUrlResourceScope()Clears the value of baseUrlResourceScope field. HttpOptions.BuilderbaseUrlResourceScope(ResourceScope.Known knownType)Setter for baseUrlResourceScope given a known enum. HttpOptions.BuilderbaseUrlResourceScope(String baseUrlResourceScope)Setter for baseUrlResourceScope given a string. abstract HttpOptions.BuilderapiVersion(String apiVersion)Setter for apiVersion. HttpOptions.BuilderclearApiVersion()Clears the value of apiVersion field. abstract HttpOptions.Builderheaders(Map<String, String> headers)Setter for headers. HttpOptions.BuilderclearHeaders()Clears the value of headers field. abstract HttpOptions.Buildertimeout(Integer timeout)Setter for timeout. HttpOptions.BuilderclearTimeout()Clears the value of timeout field. abstract HttpOptions.BuilderextraBody(Map<String, Object> extraBody)Setter for extraBody. HttpOptions.BuilderclearExtraBody()Clears the value of extraBody field. abstract HttpOptions.BuilderretryOptions(HttpRetryOptions retryOptions)Setter for retryOptions. HttpOptions.BuilderretryOptions(HttpRetryOptions.Builder retryOptionsBuilder)Setter for retryOptions builder. HttpOptions.BuilderclearRetryOptions()Clears the value of retryOptions field. abstract HttpOptionsbuild()-
-
Method Detail
-
baseUrl
abstract HttpOptions.Builder baseUrl(String baseUrl)
Setter for baseUrl.
baseUrl: The base URL for the AI platform service endpoint.
-
clearBaseUrl
@CanIgnoreReturnValue() HttpOptions.Builder clearBaseUrl()
Clears the value of baseUrl field.
-
baseUrlResourceScope
abstract HttpOptions.Builder baseUrlResourceScope(ResourceScope baseUrlResourceScope)
Setter for baseUrlResourceScope.
baseUrlResourceScope: The resource scope used to constructing the resource name when base_url is set
-
clearBaseUrlResourceScope
@CanIgnoreReturnValue() HttpOptions.Builder clearBaseUrlResourceScope()
Clears the value of baseUrlResourceScope field.
-
baseUrlResourceScope
@CanIgnoreReturnValue() HttpOptions.Builder baseUrlResourceScope(ResourceScope.Known knownType)
Setter for baseUrlResourceScope given a known enum.
baseUrlResourceScope: The resource scope used to constructing the resource name when base_url is set
-
baseUrlResourceScope
@CanIgnoreReturnValue() HttpOptions.Builder baseUrlResourceScope(String baseUrlResourceScope)
Setter for baseUrlResourceScope given a string.
baseUrlResourceScope: The resource scope used to constructing the resource name when base_url is set
-
apiVersion
abstract HttpOptions.Builder apiVersion(String apiVersion)
Setter for apiVersion.
apiVersion: Specifies the version of the API to use.
-
clearApiVersion
@CanIgnoreReturnValue() HttpOptions.Builder clearApiVersion()
Clears the value of apiVersion field.
-
headers
abstract HttpOptions.Builder headers(Map<String, String> headers)
Setter for headers.
headers: Additional HTTP headers to be sent with the request.
-
clearHeaders
@CanIgnoreReturnValue() HttpOptions.Builder clearHeaders()
Clears the value of headers field.
-
timeout
abstract HttpOptions.Builder timeout(Integer timeout)
Setter for timeout.
timeout: Timeout for the request in milliseconds.
-
clearTimeout
@CanIgnoreReturnValue() HttpOptions.Builder clearTimeout()
Clears the value of timeout field.
-
extraBody
abstract HttpOptions.Builder extraBody(Map<String, Object> extraBody)
Setter for extraBody.
extraBody: Extra parameters to add to the request body. The structure must match the backend API's request structure. - Gemini Enterprise Agent Platform backend API docs: https://cloud.google.com/vertex-ai/docs/reference/rest - GeminiAPI backend API docs: https://ai.google.dev/api/rest
-
clearExtraBody
@CanIgnoreReturnValue() HttpOptions.Builder clearExtraBody()
Clears the value of extraBody field.
-
retryOptions
abstract HttpOptions.Builder retryOptions(HttpRetryOptions retryOptions)
Setter for retryOptions.
retryOptions: HTTP retry options for the request.
-
retryOptions
@CanIgnoreReturnValue() HttpOptions.Builder retryOptions(HttpRetryOptions.Builder retryOptionsBuilder)
Setter for retryOptions builder.
retryOptions: HTTP retry options for the request.
-
clearRetryOptions
@CanIgnoreReturnValue() HttpOptions.Builder clearRetryOptions()
Clears the value of retryOptions field.
-
build
abstract HttpOptions build()
-
-
-
-