Class ProviderConfig.Builder
java.lang.Object
cloud.opencode.base.sms.config.ProviderConfig.Builder
- Enclosing class:
ProviderConfig
Builder for ProviderConfig.
ProviderConfig的构建器。
- Since:
- JDK 25, opencode-base-sms V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapiVersion(String apiVersion) Sets the API version.build()Builds the ProviderConfig.connectTimeout(Duration connectTimeout) Sets the connection timeout.Sets the API endpoint.extraOptions(Map<String, String> extraOptions) Sets extra options.maxRetries(int maxRetries) Sets the max retries.Sets the provider name.Adds an extra option.Sets the region.Sets the SDK app ID (for Tencent).Sets the request timeout.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
name
Sets the provider name. 设置服务商名称。- Parameters:
name- the name | 名称- Returns:
- this builder | 此构建器
-
endpoint
Sets the API endpoint. 设置API端点。- Parameters:
endpoint- the endpoint | 端点- Returns:
- this builder | 此构建器
-
apiVersion
Sets the API version. 设置API版本。- Parameters:
apiVersion- the API version | API版本- Returns:
- this builder | 此构建器
-
region
Sets the region. 设置区域。- Parameters:
region- the region | 区域- Returns:
- this builder | 此构建器
-
timeout
Sets the request timeout. 设置请求超时。- Parameters:
timeout- the timeout | 超时- Returns:
- this builder | 此构建器
-
connectTimeout
Sets the connection timeout. 设置连接超时。- Parameters:
connectTimeout- the connect timeout | 连接超时- Returns:
- this builder | 此构建器
-
maxRetries
Sets the max retries. 设置最大重试次数。- Parameters:
maxRetries- the max retries | 最大重试次数- Returns:
- this builder | 此构建器
-
sdkAppId
Sets the SDK app ID (for Tencent). 设置SDK应用ID(腾讯云)。- Parameters:
sdkAppId- the SDK app ID | SDK应用ID- Returns:
- this builder | 此构建器
-
extraOptions
Sets extra options. 设置额外选项。- Parameters:
extraOptions- the extra options | 额外选项- Returns:
- this builder | 此构建器
-
option
Adds an extra option. 添加额外选项。- Parameters:
key- the key | 键value- the value | 值- Returns:
- this builder | 此构建器
-
build
-