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

/**
 * Describes the diagnostics options available
 *
 */
class DiagnosticsDescription {
  /**
   * Create a DiagnosticsDescription.
   * @property {array} [sinks] List of supported sinks that can be referenced.
   * @property {boolean} [enabled] Status of whether or not sinks are enabled.
   * @property {array} [defaultSinkRefs] The sinks to be used if diagnostics is
   * enabled. Sink choices can be overridden at the service and code package
   * level.
   */
  constructor() {
  }

  /**
   * Defines the metadata of DiagnosticsDescription
   *
   * @returns {object} metadata of DiagnosticsDescription
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'DiagnosticsDescription',
      type: {
        name: 'Composite',
        className: 'DiagnosticsDescription',
        modelProperties: {
          sinks: {
            required: false,
            serializedName: 'sinks',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'DiagnosticsSinkPropertiesElementType',
                  type: {
                    name: 'Composite',
                    polymorphicDiscriminator: {
                      serializedName: 'kind',
                      clientName: 'kind'
                    },
                    uberParent: 'DiagnosticsSinkProperties',
                    className: 'DiagnosticsSinkProperties'
                  }
              }
            }
          },
          enabled: {
            required: false,
            serializedName: 'enabled',
            type: {
              name: 'Boolean'
            }
          },
          defaultSinkRefs: {
            required: false,
            serializedName: 'defaultSinkRefs',
            type: {
              name: 'Sequence',
              element: {
                  required: false,
                  serializedName: 'StringElementType',
                  type: {
                    name: 'String'
                  }
              }
            }
          }
        }
      }
    };
  }
}

module.exports = DiagnosticsDescription;
