LogsQueryClientBuilder Class
- java.
lang. Object - com.
azure. monitor. query. LogsQueryClientBuilder
- com.
Implements
public final class LogsQueryClientBuilder
implements EndpointTrait<LogsQueryClientBuilder>, HttpTrait<LogsQueryClientBuilder>, ConfigurationTrait<LogsQueryClientBuilder>, TokenCredentialTrait<LogsQueryClientBuilder>
Fluent builder for creating instances of LogsQueryClient and LogsQueryAsyncClient.
Instantiating an asynchronous Logs query Client
LogsQueryAsyncClient logsQueryAsyncClient = new LogsQueryClientBuilder()
.credential(tokenCredential)
.buildAsyncClient();
Instantiating a synchronous Logs query Client
LogsQueryClient logsQueryClient = new LogsQueryClientBuilder()
.credential(tokenCredential)
.buildClient();
Constructor Summary
| Constructor | Description | |
|---|---|---|
| LogsQueryClientBuilder() | ||
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
Logs |
addPolicy(HttpPipelinePolicy customPolicy)
Adds a custom Http pipeline policy. |
|
Logs |
buildAsyncClient()
Creates an asynchronous client with the configured options in this builder. |
|
Logs |
buildClient()
Creates a synchronous client with the configured options in this builder. |
|
Logs |
clientOptions(ClientOptions clientOptions)
Set the ClientOptions used for creating the client. |
|
Logs |
configuration(Configuration configuration)
Sets The configuration store that is used during construction of the service client. |
|
Logs |
credential(TokenCredential tokenCredential)
Sets The Token |
|
Logs |
endpoint(String endpoint)
Sets the log query endpoint. |
|
Logs |
httpClient(HttpClient httpClient)
Sets The HTTP client used to send the request. |
|
Logs |
httpLogOptions(HttpLogOptions httpLogOptions)
Sets The logging configuration for HTTP requests and responses. |
|
Logs |
pipeline(HttpPipeline pipeline)
Sets The HTTP pipeline to send requests through. |
|
Logs |
retryOptions(RetryOptions retryOptions)
Sets the RetryOptions used for creating the client. |
|
Logs |
retryPolicy(RetryPolicy retryPolicy)
Sets The retry policy that will attempt to retry failed requests, if applicable. |
|
Logs |
serviceVersion(LogsQueryServiceVersion serviceVersion)
The service version to use when creating the client. |
Methods inherited from java.lang.Object
Constructor Details
LogsQueryClientBuilder
public LogsQueryClientBuilder()
Method Details
addPolicy
public LogsQueryClientBuilder addPolicy(HttpPipelinePolicy customPolicy)
Adds a custom Http pipeline policy.
Parameters:
Returns:
buildAsyncClient
public LogsQueryAsyncClient buildAsyncClient()
Creates an asynchronous client with the configured options in this builder.
Returns:
buildClient
public LogsQueryClient buildClient()
Creates a synchronous client with the configured options in this builder.
Returns:
clientOptions
public LogsQueryClientBuilder clientOptions(ClientOptions clientOptions)
Set the ClientOptions used for creating the client.
Parameters:
Returns:
configuration
public LogsQueryClientBuilder configuration(Configuration configuration)
Sets The configuration store that is used during construction of the service client.
Parameters:
Returns:
credential
public LogsQueryClientBuilder credential(TokenCredential tokenCredential)
Sets The TokenCredential used for authentication.
Parameters:
Returns:
endpoint
public LogsQueryClientBuilder endpoint(String endpoint)
Sets the log query endpoint.
Parameters:
Returns:
httpClient
public LogsQueryClientBuilder httpClient(HttpClient httpClient)
Sets The HTTP client used to send the request.
Parameters:
Returns:
httpLogOptions
public LogsQueryClientBuilder httpLogOptions(HttpLogOptions httpLogOptions)
Sets The logging configuration for HTTP requests and responses.
Parameters:
Returns:
pipeline
public LogsQueryClientBuilder pipeline(HttpPipeline pipeline)
Sets The HTTP pipeline to send requests through.
Parameters:
Returns:
retryOptions
public LogsQueryClientBuilder retryOptions(RetryOptions retryOptions)
Sets the RetryOptions used for creating the client.
Parameters:
Returns:
retryPolicy
public LogsQueryClientBuilder retryPolicy(RetryPolicy retryPolicy)
Sets The retry policy that will attempt to retry failed requests, if applicable.
Parameters:
Returns:
serviceVersion
public LogsQueryClientBuilder serviceVersion(LogsQueryServiceVersion serviceVersion)
The service version to use when creating the client.
Parameters:
Returns: