public final class CommunicationRelayClientBuilder extends Object
Constructor and Description |
---|
CommunicationRelayClientBuilder() |
Modifier and Type | Method and Description |
---|---|
CommunicationRelayClientBuilder |
addPolicy(com.azure.core.http.policy.HttpPipelinePolicy customPolicy)
Apply additional HttpPipelinePolicy
|
CommunicationRelayAsyncClient |
buildAsyncClient()
Create asynchronous client applying HMACAuthenticationPolicy, UserAgentPolicy,
RetryPolicy, and CookiePolicy.
|
CommunicationRelayClient |
buildClient()
Create synchronous client applying HmacAuthenticationPolicy, UserAgentPolicy,
RetryPolicy, and CookiePolicy.
|
CommunicationRelayClientBuilder |
clientOptions(com.azure.core.util.ClientOptions clientOptions)
Sets the client options for all the requests made through the client.
|
CommunicationRelayClientBuilder |
configuration(com.azure.core.util.Configuration configuration)
Sets the configuration object used to retrieve environment configuration values during building of the client.
|
CommunicationRelayClientBuilder |
connectionString(String connectionString)
Set endpoint and credential to use
|
CommunicationRelayClientBuilder |
credential(com.azure.core.credential.AzureKeyCredential keyCredential)
Sets the
AzureKeyCredential used to authenticate HTTP requests. |
CommunicationRelayClientBuilder |
credential(com.azure.core.credential.TokenCredential tokenCredential)
Sets the
TokenCredential used to authenticate HTTP requests. |
CommunicationRelayClientBuilder |
endpoint(String endpoint)
Set endpoint of the service
|
CommunicationRelayClientBuilder |
httpClient(com.azure.core.http.HttpClient httpClient)
Set httpClient to use
|
CommunicationRelayClientBuilder |
httpLogOptions(com.azure.core.http.policy.HttpLogOptions logOptions)
Sets the
HttpLogOptions for service requests. |
CommunicationRelayClientBuilder |
pipeline(com.azure.core.http.HttpPipeline pipeline)
Set endpoint of the service
|
CommunicationRelayClientBuilder |
retryPolicy(com.azure.core.http.policy.RetryPolicy retryPolicy)
Sets the
RetryPolicy that is used when each request is sent. |
CommunicationRelayClientBuilder |
serviceVersion(CommunicationRelayServiceVersion version)
Sets the
CommunicationRelayServiceVersion that is used when making API requests. |
public CommunicationRelayClientBuilder endpoint(String endpoint)
endpoint
- url of the servicepublic CommunicationRelayClientBuilder pipeline(com.azure.core.http.HttpPipeline pipeline)
pipeline
- HttpPipeline to use, if a pipeline is not
supplied, the credential and httpClient fields must be setpublic CommunicationRelayClientBuilder credential(com.azure.core.credential.TokenCredential tokenCredential)
TokenCredential
used to authenticate HTTP requests.tokenCredential
- TokenCredential
used to authenticate HTTP requests.CommunicationRelayClientBuilder
object.public CommunicationRelayClientBuilder credential(com.azure.core.credential.AzureKeyCredential keyCredential)
AzureKeyCredential
used to authenticate HTTP requests.keyCredential
- The AzureKeyCredential
used to authenticate HTTP requests.CommunicationRelayClientBuilder
object.public CommunicationRelayClientBuilder connectionString(String connectionString)
connectionString
- connection string for setting endpoint and initalizing CommunicationClientCredentialpublic CommunicationRelayClientBuilder httpClient(com.azure.core.http.HttpClient httpClient)
httpClient
- httpClient to use, overridden by the pipeline
field.public CommunicationRelayClientBuilder addPolicy(com.azure.core.http.policy.HttpPipelinePolicy customPolicy)
customPolicy
- HttpPipelinePolicy object to be applied after
AzureKeyCredentialPolicy, UserAgentPolicy, RetryPolicy, and CookiePolicypublic CommunicationRelayClientBuilder clientOptions(com.azure.core.util.ClientOptions clientOptions)
clientOptions
- ClientOptions
.CommunicationRelayClientBuilder
object.public CommunicationRelayClientBuilder configuration(com.azure.core.util.Configuration configuration)
configuration
- Configuration store used to retrieve environment configurations.public CommunicationRelayClientBuilder httpLogOptions(com.azure.core.http.policy.HttpLogOptions logOptions)
HttpLogOptions
for service requests.logOptions
- The logging configuration to use when sending and receiving HTTP requests/responses.public CommunicationRelayClientBuilder retryPolicy(com.azure.core.http.policy.RetryPolicy retryPolicy)
RetryPolicy
that is used when each request is sent.retryPolicy
- User's retry policy applied to each request.CommunicationRelayClientBuilder
object.public CommunicationRelayClientBuilder serviceVersion(CommunicationRelayServiceVersion version)
CommunicationRelayServiceVersion
that is used when making API requests.
If a service version is not provided, the service version that will be used will be the latest known service version based on the version of the client library being used. If no service version is specified, updating to a newer version of the client library will have the result of potentially moving to a newer service version.
Targeting a specific service version may also mean that the service will return an error for newer APIs.
version
- CommunicationRelayServiceVersion
of the service to be used when making requests.public CommunicationRelayAsyncClient buildAsyncClient()
public CommunicationRelayClient buildClient()
Copyright © 2021 Microsoft Corporation. All rights reserved.