/*
 * 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 util = require('util');

/**
 * @class
 * Initializes a new instance of the CertificateReference class.
 * @constructor
 * A reference to a certificate to be installed on compute nodes in a pool.
 * @member {string} thumbprint The thumbprint of the certificate.
 * 
 * @member {string} thumbprintAlgorithm The algorithm with which the
 * thumbprint is associated. This must be sha1.
 * 
 * @member {string} [storeLocation] The location of the certificate store on
 * the compute node into which to install the certificate. The default value
 * is CurrentUser. Possible values include: 'currentuser', 'localmachine',
 * 'unmapped'
 * 
 * @member {string} [storeName] The name of the certificate store on the
 * compute node into which to install the certificate. The default value is
 * My.
 * 
 * @member {array} [visibility] Which user accounts on the compute node should
 * have access to the private data of the certificate. This may be any subset
 * of the values 'starttask', 'task' and 'remoteuser', separated by commas.
 * The default is all accounts, corresponding to the string
 * 'starttask,task,remoteuser'.
 * 
 */
function CertificateReference() {
}

/**
 * Defines the metadata of CertificateReference
 *
 * @returns {object} metadata of CertificateReference
 *
 */
CertificateReference.prototype.mapper = function () {
  return {
    required: false,
    serializedName: 'CertificateReference',
    type: {
      name: 'Composite',
      className: 'CertificateReference',
      modelProperties: {
        thumbprint: {
          required: true,
          serializedName: 'thumbprint',
          type: {
            name: 'String'
          }
        },
        thumbprintAlgorithm: {
          required: true,
          serializedName: 'thumbprintAlgorithm',
          type: {
            name: 'String'
          }
        },
        storeLocation: {
          required: false,
          serializedName: 'storeLocation',
          type: {
            name: 'Enum',
            allowedValues: [ 'currentuser', 'localmachine', 'unmapped' ]
          }
        },
        storeName: {
          required: false,
          serializedName: 'storeName',
          type: {
            name: 'String'
          }
        },
        visibility: {
          required: false,
          serializedName: 'visibility',
          type: {
            name: 'Sequence',
            element: {
                required: false,
                serializedName: 'CertificateVisibilityElementType',
                type: {
                  name: 'Enum',
                  allowedValues: [ 'starttask', 'task', 'remoteuser', 'unmapped' ]
                }
            }
          }
        }
      }
    }
  };
};

module.exports = CertificateReference;
