Search in sources :

Example 1 with DataLakeAnalyticsAccountUpdateParameters

use of com.microsoft.azure.management.datalake.analytics.models.DataLakeAnalyticsAccountUpdateParameters in project azure-sdk-for-java by Azure.

the class AccountsImpl method updateWithServiceResponseAsync.

/**
     * Updates the Data Lake Analytics account object specified by the accountName with the contents of the account object.
     *
     * @param resourceGroupName The name of the Azure resource group that contains the Data Lake Analytics account.
     * @param accountName The name of the Data Lake Analytics account to update.
     * @throws IllegalArgumentException thrown if parameters fail the validation
     * @return the observable for the request
     */
public Observable<ServiceResponse<DataLakeAnalyticsAccount>> updateWithServiceResponseAsync(String resourceGroupName, String accountName) {
    if (resourceGroupName == null) {
        throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
    }
    if (accountName == null) {
        throw new IllegalArgumentException("Parameter accountName is required and cannot be null.");
    }
    if (this.client.subscriptionId() == null) {
        throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null.");
    }
    if (this.client.apiVersion() == null) {
        throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null.");
    }
    final DataLakeAnalyticsAccountUpdateParameters parameters = null;
    Observable<Response<ResponseBody>> observable = service.update(resourceGroupName, accountName, this.client.subscriptionId(), parameters, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent());
    return client.getAzureClient().getPutOrPatchResultAsync(observable, new TypeToken<DataLakeAnalyticsAccount>() {
    }.getType());
}
Also used : Response(retrofit2.Response) ServiceResponse(com.microsoft.rest.ServiceResponse) DataLakeAnalyticsAccountUpdateParameters(com.microsoft.azure.management.datalake.analytics.models.DataLakeAnalyticsAccountUpdateParameters) TypeToken(com.google.common.reflect.TypeToken)

Aggregations

TypeToken (com.google.common.reflect.TypeToken)1 DataLakeAnalyticsAccountUpdateParameters (com.microsoft.azure.management.datalake.analytics.models.DataLakeAnalyticsAccountUpdateParameters)1 ServiceResponse (com.microsoft.rest.ServiceResponse)1 Response (retrofit2.Response)1