Class ComputerVisionClientImpl
- java.lang.Object
-
- com.microsoft.rest.ServiceClient
-
- com.microsoft.azure.AzureServiceClient
-
- com.microsoft.azure.cognitiveservices.vision.computervision.implementation.ComputerVisionClientImpl
-
- All Implemented Interfaces:
ComputerVisionClient
public class ComputerVisionClientImpl extends com.microsoft.azure.AzureServiceClient implements ComputerVisionClient
Initializes a new instance of the ComputerVisionClientImpl class.
-
-
Constructor Summary
Constructors Constructor Description ComputerVisionClientImpl(com.microsoft.rest.credentials.ServiceClientCredentials credentials)
Initializes an instance of ComputerVisionClient client.ComputerVisionClientImpl(com.microsoft.rest.RestClient restClient)
Initializes an instance of ComputerVisionClient client.ComputerVisionClientImpl(String baseUrl, com.microsoft.rest.credentials.ServiceClientCredentials credentials)
Initializes an instance of ComputerVisionClient client.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
acceptLanguage()
Gets Gets or sets the preferred language for the response.ComputerVision
computerVision()
Gets the ComputerVision object to access its operations.String
endpoint()
Gets Supported Cognitive Services endpoints.boolean
generateClientRequestId()
Gets When set to true a unique x-ms-client-request-id value is generated and included in each request.com.microsoft.azure.AzureClient
getAzureClient()
Gets theAzureClient
used for long running operations.protected void
initialize()
int
longRunningOperationRetryTimeout()
Gets Gets or sets the retry timeout in seconds for Long Running Operations.String
userAgent()
Gets the User-Agent header for the client.ComputerVisionClientImpl
withAcceptLanguage(String acceptLanguage)
Sets Gets or sets the preferred language for the response.ComputerVisionClientImpl
withEndpoint(String endpoint)
Sets Supported Cognitive Services endpoints.ComputerVisionClientImpl
withGenerateClientRequestId(boolean generateClientRequestId)
Sets When set to true a unique x-ms-client-request-id value is generated and included in each request.ComputerVisionClientImpl
withLongRunningOperationRetryTimeout(int longRunningOperationRetryTimeout)
Sets Gets or sets the retry timeout in seconds for Long Running Operations.-
Methods inherited from class com.microsoft.rest.ServiceClient
httpClient, restClient, retrofit, serializerAdapter
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.microsoft.azure.cognitiveservices.vision.computervision.ComputerVisionClient
restClient
-
-
-
-
Constructor Detail
-
ComputerVisionClientImpl
public ComputerVisionClientImpl(com.microsoft.rest.credentials.ServiceClientCredentials credentials)
Initializes an instance of ComputerVisionClient client.- Parameters:
credentials
- the management credentials for Azure
-
ComputerVisionClientImpl
public ComputerVisionClientImpl(String baseUrl, com.microsoft.rest.credentials.ServiceClientCredentials credentials)
Initializes an instance of ComputerVisionClient client.- Parameters:
baseUrl
- the base URL of the hostcredentials
- the management credentials for Azure
-
ComputerVisionClientImpl
public ComputerVisionClientImpl(com.microsoft.rest.RestClient restClient)
Initializes an instance of ComputerVisionClient client.- Parameters:
restClient
- the REST client to connect to Azure.
-
-
Method Detail
-
getAzureClient
public com.microsoft.azure.AzureClient getAzureClient()
Gets theAzureClient
used for long running operations.- Specified by:
getAzureClient
in interfaceComputerVisionClient
- Returns:
- the azure client;
-
endpoint
public String endpoint()
Gets Supported Cognitive Services endpoints.- Specified by:
endpoint
in interfaceComputerVisionClient
- Returns:
- the endpoint value.
-
withEndpoint
public ComputerVisionClientImpl withEndpoint(String endpoint)
Sets Supported Cognitive Services endpoints.- Specified by:
withEndpoint
in interfaceComputerVisionClient
- Parameters:
endpoint
- the endpoint value.- Returns:
- the service client itself
-
acceptLanguage
public String acceptLanguage()
Gets Gets or sets the preferred language for the response.- Specified by:
acceptLanguage
in interfaceComputerVisionClient
- Returns:
- the acceptLanguage value.
-
withAcceptLanguage
public ComputerVisionClientImpl withAcceptLanguage(String acceptLanguage)
Sets Gets or sets the preferred language for the response.- Specified by:
withAcceptLanguage
in interfaceComputerVisionClient
- Parameters:
acceptLanguage
- the acceptLanguage value.- Returns:
- the service client itself
-
longRunningOperationRetryTimeout
public int longRunningOperationRetryTimeout()
Gets Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30.- Specified by:
longRunningOperationRetryTimeout
in interfaceComputerVisionClient
- Returns:
- the longRunningOperationRetryTimeout value.
-
withLongRunningOperationRetryTimeout
public ComputerVisionClientImpl withLongRunningOperationRetryTimeout(int longRunningOperationRetryTimeout)
Sets Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30.- Specified by:
withLongRunningOperationRetryTimeout
in interfaceComputerVisionClient
- Parameters:
longRunningOperationRetryTimeout
- the longRunningOperationRetryTimeout value.- Returns:
- the service client itself
-
generateClientRequestId
public boolean generateClientRequestId()
Gets When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.- Specified by:
generateClientRequestId
in interfaceComputerVisionClient
- Returns:
- the generateClientRequestId value.
-
withGenerateClientRequestId
public ComputerVisionClientImpl withGenerateClientRequestId(boolean generateClientRequestId)
Sets When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true.- Specified by:
withGenerateClientRequestId
in interfaceComputerVisionClient
- Parameters:
generateClientRequestId
- the generateClientRequestId value.- Returns:
- the service client itself
-
computerVision
public ComputerVision computerVision()
Gets the ComputerVision object to access its operations.- Specified by:
computerVision
in interfaceComputerVisionClient
- Returns:
- the ComputerVision object.
-
initialize
protected void initialize()
-
userAgent
public String userAgent()
Gets the User-Agent header for the client.- Specified by:
userAgent
in interfaceComputerVisionClient
- Overrides:
userAgent
in classcom.microsoft.azure.AzureServiceClient
- Returns:
- the user agent string.
-
-