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

/**
 * The Amazon S3 settings needed for the interim Amazon S3 when copying from
 * Amazon Redshift with unload. With this, data from Amazon Redshift source
 * will be unloaded into S3 first and then copied into the targeted sink from
 * the interim S3.
 *
 */
class RedshiftUnloadSettings {
  /**
   * Create a RedshiftUnloadSettings.
   * @member {object} s3LinkedServiceName The name of the Amazon S3 linked
   * service which will be used for the unload operation when copying from the
   * Amazon Redshift source.
   * @member {string} [s3LinkedServiceName.referenceName] Reference
   * LinkedService name.
   * @member {object} [s3LinkedServiceName.parameters] Arguments for
   * LinkedService.
   * @member {object} bucketName The bucket of the interim Amazon S3 which will
   * be used to store the unloaded data from Amazon Redshift source. The bucket
   * must be in the same region as the Amazon Redshift source. Type: string (or
   * Expression with resultType string).
   */
  constructor() {
  }

  /**
   * Defines the metadata of RedshiftUnloadSettings
   *
   * @returns {object} metadata of RedshiftUnloadSettings
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'RedshiftUnloadSettings',
      type: {
        name: 'Composite',
        className: 'RedshiftUnloadSettings',
        modelProperties: {
          s3LinkedServiceName: {
            required: true,
            serializedName: 's3LinkedServiceName',
            defaultValue: {},
            type: {
              name: 'Composite',
              className: 'LinkedServiceReference'
            }
          },
          bucketName: {
            required: true,
            serializedName: 'bucketName',
            type: {
              name: 'Object'
            }
          }
        }
      }
    };
  }
}

module.exports = RedshiftUnloadSettings;
