/*
 * 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 execution options of a job step.
 *
 */
class JobStepExecutionOptions {
  /**
   * Create a JobStepExecutionOptions.
   * @property {number} [timeoutSeconds] Execution timeout for the job step.
   * Default value: 43200 .
   * @property {number} [retryAttempts] Maximum number of times the job step
   * will be reattempted if the first attempt fails. Default value: 10 .
   * @property {number} [initialRetryIntervalSeconds] Initial delay between
   * retries for job step execution. Default value: 1 .
   * @property {number} [maximumRetryIntervalSeconds] The maximum amount of
   * time to wait between retries for job step execution. Default value: 120 .
   * @property {number} [retryIntervalBackoffMultiplier] The backoff multiplier
   * for the time between retries. Default value: 2 .
   */
  constructor() {
  }

  /**
   * Defines the metadata of JobStepExecutionOptions
   *
   * @returns {object} metadata of JobStepExecutionOptions
   *
   */
  mapper() {
    return {
      required: false,
      serializedName: 'JobStepExecutionOptions',
      type: {
        name: 'Composite',
        className: 'JobStepExecutionOptions',
        modelProperties: {
          timeoutSeconds: {
            required: false,
            serializedName: 'timeoutSeconds',
            defaultValue: 43200,
            type: {
              name: 'Number'
            }
          },
          retryAttempts: {
            required: false,
            serializedName: 'retryAttempts',
            defaultValue: 10,
            type: {
              name: 'Number'
            }
          },
          initialRetryIntervalSeconds: {
            required: false,
            serializedName: 'initialRetryIntervalSeconds',
            defaultValue: 1,
            type: {
              name: 'Number'
            }
          },
          maximumRetryIntervalSeconds: {
            required: false,
            serializedName: 'maximumRetryIntervalSeconds',
            defaultValue: 120,
            type: {
              name: 'Number'
            }
          },
          retryIntervalBackoffMultiplier: {
            required: false,
            serializedName: 'retryIntervalBackoffMultiplier',
            defaultValue: 2,
            type: {
              name: 'Number'
            }
          }
        }
      }
    };
  }
}

module.exports = JobStepExecutionOptions;
