text: /*
   * 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';
  
  const models = require('./index');
  
  /**
   * The diagnostic setting resource.
   *
   * @extends models['ProxyOnlyResource']
   */
  class DiagnosticSettingsResource extends models['ProxyOnlyResource'] {
    /**
     * Create a DiagnosticSettingsResource.
     * @member {string} [storageAccountId] The resource ID of the storage account
     * to which you would like to send Diagnostic Logs.
     * @member {string} [serviceBusRuleId] The service bus rule Id of the
     * diagnostic setting. This is here to maintain backwards compatibility.
     * @member {string} [eventHubAuthorizationRuleId] The resource Id for the
     * event hub authorization rule.
     * @member {string} [eventHubName] The name of the event hub. If none is
     * specified, the default event hub will be selected.
     * @member {array} [metrics] the list of metric settings.
     * @member {array} [logs] the list of logs settings.
     * @member {string} [workspaceId] The workspace ID (resource ID of a Log
     * Analytics workspace) for a Log Analytics workspace to which you would like
     * to send Diagnostic Logs. Example:
     * /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
     */
    constructor() {
      super();
    }
  
    /**
     * Defines the metadata of DiagnosticSettingsResource
     *
     * @returns {object} metadata of DiagnosticSettingsResource
     *
     */
    mapper() {
      return {
        required: false,
        serializedName: 'DiagnosticSettingsResource',
        type: {
          name: 'Composite',
          className: 'DiagnosticSettingsResource',
          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'
              }
            },
            storageAccountId: {
              required: false,
              serializedName: 'properties.storageAccountId',
              type: {
                name: 'String'
              }
            },
            serviceBusRuleId: {
              required: false,
              serializedName: 'properties.serviceBusRuleId',
              type: {
                name: 'String'
              }
            },
            eventHubAuthorizationRuleId: {
              required: false,
              serializedName: 'properties.eventHubAuthorizationRuleId',
              type: {
                name: 'String'
              }
            },
            eventHubName: {
              required: false,
              serializedName: 'properties.eventHubName',
              type: {
                name: 'String'
              }
            },
            metrics: {
              required: false,
              serializedName: 'properties.metrics',
              type: {
                name: 'Sequence',
                element: {
                    required: false,
                    serializedName: 'MetricSettingsElementType',
                    type: {
                      name: 'Composite',
                      className: 'MetricSettings'
                    }
                }
              }
            },
            logs: {
              required: false,
              serializedName: 'properties.logs',
              type: {
                name: 'Sequence',
                element: {
                    required: false,
                    serializedName: 'LogSettingsElementType',
                    type: {
                      name: 'Composite',
                      className: 'LogSettings'
                    }
                }
              }
            },
            workspaceId: {
              required: false,
              serializedName: 'properties.workspaceId',
              type: {
                name: 'String'
              }
            }
          }
        }
      };
    }
  }
  
  module.exports = DiagnosticSettingsResource;
  