/*
 * 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 the Backend WebProxy Server to use in the Request to Backend.
 *
 */
class BackendProxyContract {
  /**
   * Create a BackendProxyContract.
   * @property {string} url WebProxy Server AbsoluteUri property which includes
   * the entire URI stored in the Uri instance, including all fragments and
   * query strings.
   * @property {string} [username] Username to connect to the WebProxy server
   * @property {string} [password] Password to connect to the WebProxy Server
   */
  constructor() {
  }

  /**
   * Defines the metadata of BackendProxyContract
   *
   * @returns {object} metadata of BackendProxyContract
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'BackendProxyContract',
      type: {
        name: 'Composite',
        className: 'BackendProxyContract',
        modelProperties: {
          url: {
            required: true,
            serializedName: 'url',
            constraints: {
              MaxLength: 2000,
              MinLength: 1
            },
            type: {
              name: 'String'
            }
          },
          username: {
            required: false,
            serializedName: 'username',
            type: {
              name: 'String'
            }
          },
          password: {
            required: false,
            serializedName: 'password',
            type: {
              name: 'String'
            }
          }
        }
      }
    };
  }
}

module.exports = BackendProxyContract;
