"use strict";
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
Object.defineProperty(exports, "__esModule", { value: true });
exports.MaintenanceWindowOptionsOperationsImpl = void 0;
const tslib_1 = require("tslib");
const coreClient = tslib_1.__importStar(require("@azure/core-client"));
const Mappers = tslib_1.__importStar(require("../models/mappers.js"));
const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
/** Class containing MaintenanceWindowOptionsOperations operations. */
class MaintenanceWindowOptionsOperationsImpl {
    client;
    /**
     * Initialize a new instance of the class MaintenanceWindowOptionsOperations class.
     * @param client Reference to the service client
     */
    constructor(client) {
        this.client = client;
    }
    /**
     * Gets a list of available maintenance windows.
     * @param resourceGroupName The name of the resource group that contains the resource. You can obtain
     *                          this value from the Azure Resource Manager API or the portal.
     * @param serverName The name of the server.
     * @param databaseName The name of the database to get maintenance windows options for.
     * @param maintenanceWindowOptionsName Maintenance window options name.
     * @param options The options parameters.
     */
    get(resourceGroupName, serverName, databaseName, maintenanceWindowOptionsName, options) {
        return this.client.sendOperationRequest({
            resourceGroupName,
            serverName,
            databaseName,
            maintenanceWindowOptionsName,
            options,
        }, getOperationSpec);
    }
}
exports.MaintenanceWindowOptionsOperationsImpl = MaintenanceWindowOptionsOperationsImpl;
// Operation Specifications
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
const getOperationSpec = {
    path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/maintenanceWindowOptions/current",
    httpMethod: "GET",
    responses: {
        200: {
            bodyMapper: Mappers.MaintenanceWindowOptions,
        },
        default: {},
    },
    queryParameters: [Parameters.apiVersion3, Parameters.maintenanceWindowOptionsName],
    urlParameters: [
        Parameters.$host,
        Parameters.subscriptionId,
        Parameters.resourceGroupName,
        Parameters.serverName,
        Parameters.databaseName,
    ],
    headerParameters: [Parameters.accept],
    serializer,
};
//# sourceMappingURL=maintenanceWindowOptionsOperations.js.map