1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/awstransfer/Transfer_EXPORTS.h> 8 #include <aws/awstransfer/model/WorkflowStepType.h> 9 #include <aws/awstransfer/model/CopyStepDetails.h> 10 #include <aws/awstransfer/model/CustomStepDetails.h> 11 #include <aws/awstransfer/model/DeleteStepDetails.h> 12 #include <aws/awstransfer/model/TagStepDetails.h> 13 #include <utility> 14 15 namespace Aws 16 { 17 namespace Utils 18 { 19 namespace Json 20 { 21 class JsonValue; 22 class JsonView; 23 } // namespace Json 24 } // namespace Utils 25 namespace Transfer 26 { 27 namespace Model 28 { 29 30 /** 31 * <p>The basic building block of a workflow.</p><p><h3>See Also:</h3> <a 32 * href="http://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/WorkflowStep">AWS 33 * API Reference</a></p> 34 */ 35 class AWS_TRANSFER_API WorkflowStep 36 { 37 public: 38 WorkflowStep(); 39 WorkflowStep(Aws::Utils::Json::JsonView jsonValue); 40 WorkflowStep& operator=(Aws::Utils::Json::JsonView jsonValue); 41 Aws::Utils::Json::JsonValue Jsonize() const; 42 43 44 /** 45 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 46 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 47 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 48 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 49 */ GetType()50 inline const WorkflowStepType& GetType() const{ return m_type; } 51 52 /** 53 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 54 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 55 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 56 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 57 */ TypeHasBeenSet()58 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } 59 60 /** 61 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 62 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 63 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 64 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 65 */ SetType(const WorkflowStepType & value)66 inline void SetType(const WorkflowStepType& value) { m_typeHasBeenSet = true; m_type = value; } 67 68 /** 69 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 70 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 71 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 72 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 73 */ SetType(WorkflowStepType && value)74 inline void SetType(WorkflowStepType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } 75 76 /** 77 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 78 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 79 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 80 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 81 */ WithType(const WorkflowStepType & value)82 inline WorkflowStep& WithType(const WorkflowStepType& value) { SetType(value); return *this;} 83 84 /** 85 * <p> Currently, the following step types are supported. </p> <ul> <li> <p> 86 * <i>Copy</i>: copy the file to another location</p> </li> <li> <p> <i>Custom</i>: 87 * custom step with a lambda target</p> </li> <li> <p> <i>Delete</i>: delete the 88 * file</p> </li> <li> <p> <i>Tag</i>: add a tag to the file</p> </li> </ul> 89 */ WithType(WorkflowStepType && value)90 inline WorkflowStep& WithType(WorkflowStepType&& value) { SetType(std::move(value)); return *this;} 91 92 93 /** 94 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 95 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 96 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 97 * indicates whether or not to overwrite an existing file of the same name. The 98 * default is <code>FALSE</code>.</p> </li> </ul> 99 */ GetCopyStepDetails()100 inline const CopyStepDetails& GetCopyStepDetails() const{ return m_copyStepDetails; } 101 102 /** 103 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 104 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 105 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 106 * indicates whether or not to overwrite an existing file of the same name. The 107 * default is <code>FALSE</code>.</p> </li> </ul> 108 */ CopyStepDetailsHasBeenSet()109 inline bool CopyStepDetailsHasBeenSet() const { return m_copyStepDetailsHasBeenSet; } 110 111 /** 112 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 113 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 114 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 115 * indicates whether or not to overwrite an existing file of the same name. The 116 * default is <code>FALSE</code>.</p> </li> </ul> 117 */ SetCopyStepDetails(const CopyStepDetails & value)118 inline void SetCopyStepDetails(const CopyStepDetails& value) { m_copyStepDetailsHasBeenSet = true; m_copyStepDetails = value; } 119 120 /** 121 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 122 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 123 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 124 * indicates whether or not to overwrite an existing file of the same name. The 125 * default is <code>FALSE</code>.</p> </li> </ul> 126 */ SetCopyStepDetails(CopyStepDetails && value)127 inline void SetCopyStepDetails(CopyStepDetails&& value) { m_copyStepDetailsHasBeenSet = true; m_copyStepDetails = std::move(value); } 128 129 /** 130 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 131 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 132 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 133 * indicates whether or not to overwrite an existing file of the same name. The 134 * default is <code>FALSE</code>.</p> </li> </ul> 135 */ WithCopyStepDetails(const CopyStepDetails & value)136 inline WorkflowStep& WithCopyStepDetails(const CopyStepDetails& value) { SetCopyStepDetails(value); return *this;} 137 138 /** 139 * <p>Details for a step that performs a file copy.</p> <p> Consists of the 140 * following values: </p> <ul> <li> <p>A description</p> </li> <li> <p>An S3 141 * location for the destination of the file copy.</p> </li> <li> <p>A flag that 142 * indicates whether or not to overwrite an existing file of the same name. The 143 * default is <code>FALSE</code>.</p> </li> </ul> 144 */ WithCopyStepDetails(CopyStepDetails && value)145 inline WorkflowStep& WithCopyStepDetails(CopyStepDetails&& value) { SetCopyStepDetails(std::move(value)); return *this;} 146 147 148 /** 149 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 150 * lambda function name, target, and timeout (in seconds). </p> 151 */ GetCustomStepDetails()152 inline const CustomStepDetails& GetCustomStepDetails() const{ return m_customStepDetails; } 153 154 /** 155 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 156 * lambda function name, target, and timeout (in seconds). </p> 157 */ CustomStepDetailsHasBeenSet()158 inline bool CustomStepDetailsHasBeenSet() const { return m_customStepDetailsHasBeenSet; } 159 160 /** 161 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 162 * lambda function name, target, and timeout (in seconds). </p> 163 */ SetCustomStepDetails(const CustomStepDetails & value)164 inline void SetCustomStepDetails(const CustomStepDetails& value) { m_customStepDetailsHasBeenSet = true; m_customStepDetails = value; } 165 166 /** 167 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 168 * lambda function name, target, and timeout (in seconds). </p> 169 */ SetCustomStepDetails(CustomStepDetails && value)170 inline void SetCustomStepDetails(CustomStepDetails&& value) { m_customStepDetailsHasBeenSet = true; m_customStepDetails = std::move(value); } 171 172 /** 173 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 174 * lambda function name, target, and timeout (in seconds). </p> 175 */ WithCustomStepDetails(const CustomStepDetails & value)176 inline WorkflowStep& WithCustomStepDetails(const CustomStepDetails& value) { SetCustomStepDetails(value); return *this;} 177 178 /** 179 * <p>Details for a step that invokes a lambda function.</p> <p> Consists of the 180 * lambda function name, target, and timeout (in seconds). </p> 181 */ WithCustomStepDetails(CustomStepDetails && value)182 inline WorkflowStep& WithCustomStepDetails(CustomStepDetails&& value) { SetCustomStepDetails(std::move(value)); return *this;} 183 184 185 /** 186 * <p>Details for a step that deletes the file.</p> 187 */ GetDeleteStepDetails()188 inline const DeleteStepDetails& GetDeleteStepDetails() const{ return m_deleteStepDetails; } 189 190 /** 191 * <p>Details for a step that deletes the file.</p> 192 */ DeleteStepDetailsHasBeenSet()193 inline bool DeleteStepDetailsHasBeenSet() const { return m_deleteStepDetailsHasBeenSet; } 194 195 /** 196 * <p>Details for a step that deletes the file.</p> 197 */ SetDeleteStepDetails(const DeleteStepDetails & value)198 inline void SetDeleteStepDetails(const DeleteStepDetails& value) { m_deleteStepDetailsHasBeenSet = true; m_deleteStepDetails = value; } 199 200 /** 201 * <p>Details for a step that deletes the file.</p> 202 */ SetDeleteStepDetails(DeleteStepDetails && value)203 inline void SetDeleteStepDetails(DeleteStepDetails&& value) { m_deleteStepDetailsHasBeenSet = true; m_deleteStepDetails = std::move(value); } 204 205 /** 206 * <p>Details for a step that deletes the file.</p> 207 */ WithDeleteStepDetails(const DeleteStepDetails & value)208 inline WorkflowStep& WithDeleteStepDetails(const DeleteStepDetails& value) { SetDeleteStepDetails(value); return *this;} 209 210 /** 211 * <p>Details for a step that deletes the file.</p> 212 */ WithDeleteStepDetails(DeleteStepDetails && value)213 inline WorkflowStep& WithDeleteStepDetails(DeleteStepDetails&& value) { SetDeleteStepDetails(std::move(value)); return *this;} 214 215 216 /** 217 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 218 * more tags: each tag contains a key/value pair.</p> 219 */ GetTagStepDetails()220 inline const TagStepDetails& GetTagStepDetails() const{ return m_tagStepDetails; } 221 222 /** 223 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 224 * more tags: each tag contains a key/value pair.</p> 225 */ TagStepDetailsHasBeenSet()226 inline bool TagStepDetailsHasBeenSet() const { return m_tagStepDetailsHasBeenSet; } 227 228 /** 229 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 230 * more tags: each tag contains a key/value pair.</p> 231 */ SetTagStepDetails(const TagStepDetails & value)232 inline void SetTagStepDetails(const TagStepDetails& value) { m_tagStepDetailsHasBeenSet = true; m_tagStepDetails = value; } 233 234 /** 235 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 236 * more tags: each tag contains a key/value pair.</p> 237 */ SetTagStepDetails(TagStepDetails && value)238 inline void SetTagStepDetails(TagStepDetails&& value) { m_tagStepDetailsHasBeenSet = true; m_tagStepDetails = std::move(value); } 239 240 /** 241 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 242 * more tags: each tag contains a key/value pair.</p> 243 */ WithTagStepDetails(const TagStepDetails & value)244 inline WorkflowStep& WithTagStepDetails(const TagStepDetails& value) { SetTagStepDetails(value); return *this;} 245 246 /** 247 * <p>Details for a step that creates one or more tags.</p> <p>You specify one or 248 * more tags: each tag contains a key/value pair.</p> 249 */ WithTagStepDetails(TagStepDetails && value)250 inline WorkflowStep& WithTagStepDetails(TagStepDetails&& value) { SetTagStepDetails(std::move(value)); return *this;} 251 252 private: 253 254 WorkflowStepType m_type; 255 bool m_typeHasBeenSet; 256 257 CopyStepDetails m_copyStepDetails; 258 bool m_copyStepDetailsHasBeenSet; 259 260 CustomStepDetails m_customStepDetails; 261 bool m_customStepDetailsHasBeenSet; 262 263 DeleteStepDetails m_deleteStepDetails; 264 bool m_deleteStepDetailsHasBeenSet; 265 266 TagStepDetails m_tagStepDetails; 267 bool m_tagStepDetailsHasBeenSet; 268 }; 269 270 } // namespace Model 271 } // namespace Transfer 272 } // namespace Aws 273