/**
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * SPDX-License-Identifier: Apache-2.0.
 */

#pragma once
#include <aws/awstransfer/Transfer_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>

#include <utility>

namespace Aws {
namespace Utils {
namespace Json {
class JsonValue;
class JsonView;
}  // namespace Json
}  // namespace Utils
namespace Transfer {
namespace Model {

/**
 * <p>Each step type has its own <code>StepDetails</code> structure.</p><p><h3>See
 * Also:</h3>   <a
 * href="http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CustomStepDetails">AWS
 * API Reference</a></p>
 */
class CustomStepDetails {
 public:
  AWS_TRANSFER_API CustomStepDetails() = default;
  AWS_TRANSFER_API CustomStepDetails(Aws::Utils::Json::JsonView jsonValue);
  AWS_TRANSFER_API CustomStepDetails& operator=(Aws::Utils::Json::JsonView jsonValue);
  AWS_TRANSFER_API Aws::Utils::Json::JsonValue Jsonize() const;

  ///@{
  /**
   * <p>The name of the step, used as an identifier.</p>
   */
  inline const Aws::String& GetName() const { return m_name; }
  inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
  template <typename NameT = Aws::String>
  void SetName(NameT&& value) {
    m_nameHasBeenSet = true;
    m_name = std::forward<NameT>(value);
  }
  template <typename NameT = Aws::String>
  CustomStepDetails& WithName(NameT&& value) {
    SetName(std::forward<NameT>(value));
    return *this;
  }
  ///@}

  ///@{
  /**
   * <p>The ARN for the Lambda function that is being called.</p>
   */
  inline const Aws::String& GetTarget() const { return m_target; }
  inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
  template <typename TargetT = Aws::String>
  void SetTarget(TargetT&& value) {
    m_targetHasBeenSet = true;
    m_target = std::forward<TargetT>(value);
  }
  template <typename TargetT = Aws::String>
  CustomStepDetails& WithTarget(TargetT&& value) {
    SetTarget(std::forward<TargetT>(value));
    return *this;
  }
  ///@}

  ///@{
  /**
   * <p>Timeout, in seconds, for the step.</p>
   */
  inline int GetTimeoutSeconds() const { return m_timeoutSeconds; }
  inline bool TimeoutSecondsHasBeenSet() const { return m_timeoutSecondsHasBeenSet; }
  inline void SetTimeoutSeconds(int value) {
    m_timeoutSecondsHasBeenSet = true;
    m_timeoutSeconds = value;
  }
  inline CustomStepDetails& WithTimeoutSeconds(int value) {
    SetTimeoutSeconds(value);
    return *this;
  }
  ///@}

  ///@{
  /**
   * <p>Specifies which file to use as input to the workflow step: either the output
   * from the previous step, or the originally uploaded file for the workflow.</p>
   * <ul> <li> <p>To use the previous file as the input, enter
   * <code>${previous.file}</code>. In this case, this workflow step uses the output
   * file from the previous workflow step as input. This is the default value.</p>
   * </li> <li> <p>To use the originally uploaded file location as input for this
   * step, enter <code>${original.file}</code>.</p> </li> </ul>
   */
  inline const Aws::String& GetSourceFileLocation() const { return m_sourceFileLocation; }
  inline bool SourceFileLocationHasBeenSet() const { return m_sourceFileLocationHasBeenSet; }
  template <typename SourceFileLocationT = Aws::String>
  void SetSourceFileLocation(SourceFileLocationT&& value) {
    m_sourceFileLocationHasBeenSet = true;
    m_sourceFileLocation = std::forward<SourceFileLocationT>(value);
  }
  template <typename SourceFileLocationT = Aws::String>
  CustomStepDetails& WithSourceFileLocation(SourceFileLocationT&& value) {
    SetSourceFileLocation(std::forward<SourceFileLocationT>(value));
    return *this;
  }
  ///@}
 private:
  Aws::String m_name;
  bool m_nameHasBeenSet = false;

  Aws::String m_target;
  bool m_targetHasBeenSet = false;

  int m_timeoutSeconds{0};
  bool m_timeoutSecondsHasBeenSet = false;

  Aws::String m_sourceFileLocation;
  bool m_sourceFileLocationHasBeenSet = false;
};

}  // namespace Model
}  // namespace Transfer
}  // namespace Aws
