/*
 * 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.
 * Changes may cause incorrect behavior and will be lost if the code is
 * regenerated.
 */

'use strict';

/**
 * Details of server name request body.
 *
 */
class CheckServerNameAvailabilityParameters {
  /**
   * Create a CheckServerNameAvailabilityParameters.
   * @member {string} [name] Name for checking availability.
   * @member {string} [type] The resource type of azure analysis services.
   * Default value: 'Microsoft.AnalysisServices/servers' .
   */
  constructor() {
  }

  /**
   * Defines the metadata of CheckServerNameAvailabilityParameters
   *
   * @returns {object} metadata of CheckServerNameAvailabilityParameters
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'CheckServerNameAvailabilityParameters',
      type: {
        name: 'Composite',
        className: 'CheckServerNameAvailabilityParameters',
        modelProperties: {
          name: {
            required: false,
            serializedName: 'name',
            constraints: {
              MaxLength: 63,
              MinLength: 3,
              Pattern: '^[a-z][a-z0-9]*$'
            },
            type: {
              name: 'String'
            }
          },
          type: {
            required: false,
            serializedName: 'type',
            defaultValue: 'Microsoft.AnalysisServices/servers',
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = CheckServerNameAvailabilityParameters;
