// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.hdinsight.fluent;

import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
import com.azure.resourcemanager.hdinsight.fluent.models.AsyncOperationResultInner;
import com.azure.resourcemanager.hdinsight.fluent.models.BillingResponseListResultInner;
import com.azure.resourcemanager.hdinsight.fluent.models.CapabilitiesResultInner;
import com.azure.resourcemanager.hdinsight.fluent.models.ClusterCreateValidationResultInner;
import com.azure.resourcemanager.hdinsight.fluent.models.NameAvailabilityCheckResultInner;
import com.azure.resourcemanager.hdinsight.fluent.models.UsagesListResultInner;
import com.azure.resourcemanager.hdinsight.models.ClusterCreateRequestValidationParameters;
import com.azure.resourcemanager.hdinsight.models.NameAvailabilityCheckRequestParameters;

/** An instance of this class provides access to all the operations defined in LocationsClient. */
public interface LocationsClient {
    /**
     * Gets the capabilities for the specified location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the capabilities for the specified location along with {@link Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<CapabilitiesResultInner> getCapabilitiesWithResponse(String location, Context context);

    /**
     * Gets the capabilities for the specified location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the capabilities for the specified location.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    CapabilitiesResultInner getCapabilities(String location);

    /**
     * Lists the usages for the specified location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response for the operation to get regional usages for a subscription along with {@link Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<UsagesListResultInner> listUsagesWithResponse(String location, Context context);

    /**
     * Lists the usages for the specified location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response for the operation to get regional usages for a subscription.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    UsagesListResultInner listUsages(String location);

    /**
     * Lists the billingSpecs for the specified subscription and location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response for the operation to get regional billingSpecs for a subscription along with {@link
     *     Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<BillingResponseListResultInner> listBillingSpecsWithResponse(String location, Context context);

    /**
     * Lists the billingSpecs for the specified subscription and location.
     *
     * @param location The Azure location (region) for which to make the request.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response for the operation to get regional billingSpecs for a subscription.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    BillingResponseListResultInner listBillingSpecs(String location);

    /**
     * Get the async operation status.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param operationId The long running operation id.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the async operation status along with {@link Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<AsyncOperationResultInner> getAzureAsyncOperationStatusWithResponse(
        String location, String operationId, Context context);

    /**
     * Get the async operation status.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param operationId The long running operation id.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the async operation status.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    AsyncOperationResultInner getAzureAsyncOperationStatus(String location, String operationId);

    /**
     * Check the cluster name is available or not.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param parameters The request spec of checking name availability.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response spec of checking name availability along with {@link Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<NameAvailabilityCheckResultInner> checkNameAvailabilityWithResponse(
        String location, NameAvailabilityCheckRequestParameters parameters, Context context);

    /**
     * Check the cluster name is available or not.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param parameters The request spec of checking name availability.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response spec of checking name availability.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    NameAvailabilityCheckResultInner checkNameAvailability(
        String location, NameAvailabilityCheckRequestParameters parameters);

    /**
     * Validate the cluster create request spec is valid or not.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param parameters The cluster create request specification.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response of cluster create request validation along with {@link Response}.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    Response<ClusterCreateValidationResultInner> validateClusterCreateRequestWithResponse(
        String location, ClusterCreateRequestValidationParameters parameters, Context context);

    /**
     * Validate the cluster create request spec is valid or not.
     *
     * @param location The Azure location (region) for which to make the request.
     * @param parameters The cluster create request specification.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the response of cluster create request validation.
     */
    @ServiceMethod(returns = ReturnType.SINGLE)
    ClusterCreateValidationResultInner validateClusterCreateRequest(
        String location, ClusterCreateRequestValidationParameters parameters);
}
