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

/**
 * Http logs configuration.
 *
 */
class HttpLogsConfig {
  /**
   * Create a HttpLogsConfig.
   * @member {object} [fileSystem] Http logs to file system configuration.
   * @member {number} [fileSystem.retentionInMb] Maximum size in megabytes that
   * http log files can use.
   * When reached old log files will be removed to make space for new ones.
   * Value can range between 25 and 100.
   * @member {number} [fileSystem.retentionInDays] Retention in days.
   * Remove files older than X days.
   * 0 or lower means no retention.
   * @member {boolean} [fileSystem.enabled] True if configuration is enabled,
   * false if it is disabled and null if configuration is not set.
   * @member {object} [azureBlobStorage] Http logs to azure blob storage
   * configuration.
   * @member {string} [azureBlobStorage.sasUrl] SAS url to a azure blob
   * container with read/write/list/delete permissions.
   * @member {number} [azureBlobStorage.retentionInDays] Retention in days.
   * Remove blobs older than X days.
   * 0 or lower means no retention.
   * @member {boolean} [azureBlobStorage.enabled] True if configuration is
   * enabled, false if it is disabled and null if configuration is not set.
   */
  constructor() {
  }

  /**
   * Defines the metadata of HttpLogsConfig
   *
   * @returns {object} metadata of HttpLogsConfig
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'HttpLogsConfig',
      type: {
        name: 'Composite',
        className: 'HttpLogsConfig',
        modelProperties: {
          fileSystem: {
            required: false,
            serializedName: 'fileSystem',
            type: {
              name: 'Composite',
              className: 'FileSystemHttpLogsConfig'
            }
          },
          azureBlobStorage: {
            required: false,
            serializedName: 'azureBlobStorage',
            type: {
              name: 'Composite',
              className: 'AzureBlobStorageHttpLogsConfig'
            }
          }
        }
      }
    };
  }
}

module.exports = HttpLogsConfig;
