diff --git a/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServiceClientImpl.java b/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServiceClientImpl.java new file mode 100644 index 00000000000..dc451384bcf --- /dev/null +++ b/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServiceClientImpl.java @@ -0,0 +1,197 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.containerservice.implementation; + +import com.microsoft.azure.AzureClient; +import com.microsoft.azure.AzureServiceClient; +import com.microsoft.rest.credentials.ServiceClientCredentials; +import com.microsoft.rest.RestClient; + +/** + * Initializes a new instance of the ContainerServiceClientImpl class. + */ +public class ContainerServiceClientImpl extends AzureServiceClient { + /** the {@link AzureClient} used for long running operations. */ + private AzureClient azureClient; + + /** + * Gets the {@link AzureClient} used for long running operations. + * @return the azure client; + */ + public AzureClient getAzureClient() { + return this.azureClient; + } + + /** Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. */ + private String subscriptionId; + + /** + * Gets Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. + * + * @return the subscriptionId value. + */ + public String subscriptionId() { + return this.subscriptionId; + } + + /** + * Sets Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. + * + * @param subscriptionId the subscriptionId value. + * @return the service client itself + */ + public ContainerServiceClientImpl withSubscriptionId(String subscriptionId) { + this.subscriptionId = subscriptionId; + return this; + } + + /** Gets or sets the preferred language for the response. */ + private String acceptLanguage; + + /** + * Gets Gets or sets the preferred language for the response. + * + * @return the acceptLanguage value. + */ + public String acceptLanguage() { + return this.acceptLanguage; + } + + /** + * Sets Gets or sets the preferred language for the response. + * + * @param acceptLanguage the acceptLanguage value. + * @return the service client itself + */ + public ContainerServiceClientImpl withAcceptLanguage(String acceptLanguage) { + this.acceptLanguage = acceptLanguage; + return this; + } + + /** Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. */ + private int longRunningOperationRetryTimeout; + + /** + * Gets Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. + * + * @return the longRunningOperationRetryTimeout value. + */ + public int longRunningOperationRetryTimeout() { + return this.longRunningOperationRetryTimeout; + } + + /** + * Sets Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. + * + * @param longRunningOperationRetryTimeout the longRunningOperationRetryTimeout value. + * @return the service client itself + */ + public ContainerServiceClientImpl withLongRunningOperationRetryTimeout(int longRunningOperationRetryTimeout) { + this.longRunningOperationRetryTimeout = longRunningOperationRetryTimeout; + return this; + } + + /** When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. */ + private 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. + * + * @return the generateClientRequestId value. + */ + public boolean generateClientRequestId() { + return this.generateClientRequestId; + } + + /** + * Sets When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. + * + * @param generateClientRequestId the generateClientRequestId value. + * @return the service client itself + */ + public ContainerServiceClientImpl withGenerateClientRequestId(boolean generateClientRequestId) { + this.generateClientRequestId = generateClientRequestId; + return this; + } + + /** + * The ContainerServicesInner object to access its operations. + */ + private ContainerServicesInner containerServices; + + /** + * Gets the ContainerServicesInner object to access its operations. + * @return the ContainerServicesInner object. + */ + public ContainerServicesInner containerServices() { + return this.containerServices; + } + + /** + * The ManagedClustersInner object to access its operations. + */ + private ManagedClustersInner managedClusters; + + /** + * Gets the ManagedClustersInner object to access its operations. + * @return the ManagedClustersInner object. + */ + public ManagedClustersInner managedClusters() { + return this.managedClusters; + } + + /** + * Initializes an instance of ContainerServiceClient client. + * + * @param credentials the management credentials for Azure + */ + public ContainerServiceClientImpl(ServiceClientCredentials credentials) { + this("https://management.azure.com", credentials); + } + + /** + * Initializes an instance of ContainerServiceClient client. + * + * @param baseUrl the base URL of the host + * @param credentials the management credentials for Azure + */ + public ContainerServiceClientImpl(String baseUrl, ServiceClientCredentials credentials) { + super(baseUrl, credentials); + initialize(); + } + + /** + * Initializes an instance of ContainerServiceClient client. + * + * @param restClient the REST client to connect to Azure. + */ + public ContainerServiceClientImpl(RestClient restClient) { + super(restClient); + initialize(); + } + + protected void initialize() { + this.acceptLanguage = "en-US"; + this.longRunningOperationRetryTimeout = 30; + this.generateClientRequestId = true; + this.containerServices = new ContainerServicesInner(restClient().retrofit(), this); + this.managedClusters = new ManagedClustersInner(restClient().retrofit(), this); + this.azureClient = new AzureClient(this); + } + + /** + * Gets the User-Agent header for the client. + * + * @return the user agent string. + */ + @Override + public String userAgent() { + return String.format("%s (%s)", super.userAgent(), "ContainerServiceClient"); + } +} diff --git a/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServicesInner.java b/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServicesInner.java index 62bfbd624d2..10b175886b4 100644 --- a/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServicesInner.java +++ b/azure-mgmt-containerservice/src/main/java/com/microsoft/azure/management/containerservice/implementation/ContainerServicesInner.java @@ -46,7 +46,7 @@ public class ContainerServicesInner implements InnerSupportsGet