/*
 * 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 0.15.0.0
 * 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 RedisCreateOrUpdateParameters class.
 * @constructor
 * Parameters supplied to the CreateOrUpdate Redis operation.
 * @member {string} [redisVersion] RedisVersion parameter has been deprecated.
 * As such, it is no longer necessary to provide this parameter and any value
 * specified is ignored.
 * 
 * @member {object} sku What sku of redis cache to deploy.
 * 
 * @member {string} [sku.name] What type of redis cache to deploy. Valid
 * values: (Basic, Standard, Premium). Possible values include: 'Basic',
 * 'Standard', 'Premium'
 * 
 * @member {string} [sku.family] Which family to use. Valid values: (C, P).
 * Possible values include: 'C', 'P'
 * 
 * @member {number} [sku.capacity] What size of redis cache to deploy. Valid
 * values: for C family (0, 1, 2, 3, 4, 5, 6), for P family (1, 2, 3, 4)
 * 
 * @member {object} [redisConfiguration] All Redis Settings. Few possible
 * keys: <para>rdb-backup-enabled</para><para>rdb-storage-connection-string</para><para>rdb-backup-frequency</para><para>maxmemory-delta</para><para>maxmemory-policy</para><para>notify-keyspace-events</para><para>maxmemory-samples</para><para>slowlog-log-slower-than</para><para>slowlog-max-len</para><para>list-max-ziplist-entries</para><para>list-max-ziplist-value</para><para>hash-max-ziplist-entries</para><para>hash-max-ziplist-value</para><para>set-max-intset-entries</para><para>zset-max-ziplist-entries</para><para>zset-max-ziplist-value
 * etc.</para>
 * 
 * @member {boolean} [enableNonSslPort] If the value is true, then the non-ssl
 * redis server port (6379) will be enabled.
 * 
 * @member {object} [tenantSettings] tenantSettings
 * 
 * @member {number} [shardCount] The number of shards to be created on a
 * Premium Cluster Cache.
 * 
 * @member {string} [virtualNetwork] The exact ARM resource ID of the virtual
 * network to deploy the redis cache in. Example format:
 * /subscriptions/{subid}/resourceGroups/{resourceGroupName}/Microsoft.ClassicNetwork/VirtualNetworks/vnet1
 * 
 * @member {string} [subnet] Required when deploying a redis cache inside an
 * existing Azure Virtual Network.
 * 
 * @member {string} [staticIP] Required when deploying a redis cache inside an
 * existing Azure Virtual Network.
 * 
 */
function RedisCreateOrUpdateParameters() {
  RedisCreateOrUpdateParameters['super_'].call(this);
}

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

/**
 * Defines the metadata of RedisCreateOrUpdateParameters
 *
 * @returns {object} metadata of RedisCreateOrUpdateParameters
 *
 */
RedisCreateOrUpdateParameters.prototype.mapper = function () {
  return {
    required: false,
    serializedName: 'RedisCreateOrUpdateParameters',
    type: {
      name: 'Composite',
      className: 'RedisCreateOrUpdateParameters',
      modelProperties: {
        id: {
          required: false,
          serializedName: 'id',
          type: {
            name: 'String'
          }
        },
        name: {
          required: false,
          serializedName: 'name',
          type: {
            name: 'String'
          }
        },
        type: {
          required: false,
          serializedName: 'type',
          type: {
            name: 'String'
          }
        },
        location: {
          required: true,
          serializedName: 'location',
          type: {
            name: 'String'
          }
        },
        tags: {
          required: false,
          serializedName: 'tags',
          type: {
            name: 'Dictionary',
            value: {
                required: false,
                serializedName: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        redisVersion: {
          required: false,
          serializedName: 'properties.redisVersion',
          type: {
            name: 'String'
          }
        },
        sku: {
          required: true,
          serializedName: 'properties.sku',
          type: {
            name: 'Composite',
            className: 'Sku'
          }
        },
        redisConfiguration: {
          required: false,
          serializedName: 'properties.redisConfiguration',
          type: {
            name: 'Dictionary',
            value: {
                required: false,
                serializedName: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        enableNonSslPort: {
          required: false,
          serializedName: 'properties.enableNonSslPort',
          type: {
            name: 'Boolean'
          }
        },
        tenantSettings: {
          required: false,
          serializedName: 'properties.tenantSettings',
          type: {
            name: 'Dictionary',
            value: {
                required: false,
                serializedName: 'StringElementType',
                type: {
                  name: 'String'
                }
            }
          }
        },
        shardCount: {
          required: false,
          serializedName: 'properties.shardCount',
          type: {
            name: 'Number'
          }
        },
        virtualNetwork: {
          required: false,
          serializedName: 'properties.virtualNetwork',
          type: {
            name: 'String'
          }
        },
        subnet: {
          required: false,
          serializedName: 'properties.subnet',
          type: {
            name: 'String'
          }
        },
        staticIP: {
          required: false,
          serializedName: 'properties.staticIP',
          type: {
            name: 'String'
          }
        }
      }
    }
  };
};

module.exports = RedisCreateOrUpdateParameters;
