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

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

var util = require('util');

/**
 * @class
 * Initializes a new instance of the AccountResource class.
 * @constructor
 * Contains information about an Azure Batch account.
 * @member {string} [accountEndpoint] The endpoint used by this account to
 * interact with the Batch services.
 * 
 * @member {string} [provisioningState] The provisioned state of the resource.
 * Possible values include: 'Invalid', 'Creating', 'Deleting', 'Succeeded',
 * 'Failed', 'Cancelled'
 * 
 * @member {object} [autoStorage] The properties and status of any auto
 * storage account associated with the account.
 * 
 * @member {string} [autoStorage.storageAccountId] The resource id of the
 * storage account to be used for auto storage account.
 * 
 * @member {date} [autoStorage.lastKeySync] The UTC time at which storage keys
 * were last synchronized with the Batch account.
 * 
 * @member {number} coreQuota The core quota for this Batch account.
 * 
 * @member {number} poolQuota The pool quota for this Batch account.
 * 
 * @member {number} activeJobAndJobScheduleQuota The active job and job
 * schedule quota for this Batch account.
 * 
 */
function AccountResource() {
  AccountResource['super_'].call(this);
}

util.inherits(AccountResource, models['Resource']);

/**
 * Defines the metadata of AccountResource
 *
 * @returns {object} metadata of AccountResource
 *
 */
AccountResource.prototype.mapper = function () {
  return {
    required: false,
    serializedName: 'AccountResource',
    type: {
      name: 'Composite',
      className: 'AccountResource',
      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'
          }
        },
        location: {
          required: false,
          serializedName: 'location',
          type: {
            name: 'String'
          }
        },
        tags: {
          required: false,
          serializedName: 'tags',
          type: {
            name: 'Dictionary',
            value: {
                required: false,
                serializedName: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        accountEndpoint: {
          required: false,
          serializedName: 'properties.accountEndpoint',
          type: {
            name: 'String'
          }
        },
        provisioningState: {
          required: false,
          serializedName: 'properties.provisioningState',
          type: {
            name: 'Enum',
            allowedValues: [ 'Invalid', 'Creating', 'Deleting', 'Succeeded', 'Failed', 'Cancelled' ]
          }
        },
        autoStorage: {
          required: false,
          serializedName: 'properties.autoStorage',
          type: {
            name: 'Composite',
            className: 'AutoStorageProperties'
          }
        },
        coreQuota: {
          required: true,
          serializedName: 'properties.coreQuota',
          type: {
            name: 'Number'
          }
        },
        poolQuota: {
          required: true,
          serializedName: 'properties.poolQuota',
          type: {
            name: 'Number'
          }
        },
        activeJobAndJobScheduleQuota: {
          required: true,
          serializedName: 'properties.activeJobAndJobScheduleQuota',
          type: {
            name: 'Number'
          }
        }
      }
    }
  };
};

module.exports = AccountResource;
