/*
 * 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';

const models = require('./index');

/**
 * Gateway details.
 *
 * @extends models['Resource']
 */
class GatewayContract extends models['Resource'] {
  /**
   * Create a GatewayContract.
   * @property {object} [locationData] Gateway location.
   * @property {string} [locationData.name] A canonical name for the geographic
   * or physical location.
   * @property {string} [locationData.city] The city or locality where the
   * resource is located.
   * @property {string} [locationData.district] The district, state, or
   * province where the resource is located.
   * @property {string} [locationData.countryOrRegion] The country or region
   * where the resource is located.
   * @property {string} [description] Gateway description
   */
  constructor() {
    super();
  }

  /**
   * Defines the metadata of GatewayContract
   *
   * @returns {object} metadata of GatewayContract
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'GatewayContract',
      type: {
        name: 'Composite',
        className: 'GatewayContract',
        modelProperties: {
          id: {
            required: false,
            readOnly: true,
            serializedName: 'id',
            type: {
              name: 'String'
            }
          },
          name: {
            required: false,
            readOnly: true,
            serializedName: 'name',
            type: {
              name: 'String'
            }
          },
          type: {
            required: false,
            readOnly: true,
            serializedName: 'type',
            type: {
              name: 'String'
            }
          },
          locationData: {
            required: false,
            serializedName: 'properties.locationData',
            type: {
              name: 'Composite',
              className: 'ResourceLocationDataContract'
            }
          },
          description: {
            required: false,
            serializedName: 'properties.description',
            constraints: {
              MaxLength: 1000
            },
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = GatewayContract;
