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/eventbridge/EventBridge_EXPORTS.h> 8 #include <aws/eventbridge/EventBridgeRequest.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <utility> 11 12 namespace Aws 13 { 14 namespace EventBridge 15 { 16 namespace Model 17 { 18 19 /** 20 */ 21 class AWS_EVENTBRIDGE_API CreateArchiveRequest : public EventBridgeRequest 22 { 23 public: 24 CreateArchiveRequest(); 25 26 // Service request name is the Operation name which will send this request out, 27 // each operation should has unique request name, so that we can get operation's name from this request. 28 // Note: this is not true for response, multiple operations may have the same response name, 29 // so we can not get operation's name from response. GetServiceRequestName()30 inline virtual const char* GetServiceRequestName() const override { return "CreateArchive"; } 31 32 Aws::String SerializePayload() const override; 33 34 Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; 35 36 37 /** 38 * <p>The name for the archive to create.</p> 39 */ GetArchiveName()40 inline const Aws::String& GetArchiveName() const{ return m_archiveName; } 41 42 /** 43 * <p>The name for the archive to create.</p> 44 */ ArchiveNameHasBeenSet()45 inline bool ArchiveNameHasBeenSet() const { return m_archiveNameHasBeenSet; } 46 47 /** 48 * <p>The name for the archive to create.</p> 49 */ SetArchiveName(const Aws::String & value)50 inline void SetArchiveName(const Aws::String& value) { m_archiveNameHasBeenSet = true; m_archiveName = value; } 51 52 /** 53 * <p>The name for the archive to create.</p> 54 */ SetArchiveName(Aws::String && value)55 inline void SetArchiveName(Aws::String&& value) { m_archiveNameHasBeenSet = true; m_archiveName = std::move(value); } 56 57 /** 58 * <p>The name for the archive to create.</p> 59 */ SetArchiveName(const char * value)60 inline void SetArchiveName(const char* value) { m_archiveNameHasBeenSet = true; m_archiveName.assign(value); } 61 62 /** 63 * <p>The name for the archive to create.</p> 64 */ WithArchiveName(const Aws::String & value)65 inline CreateArchiveRequest& WithArchiveName(const Aws::String& value) { SetArchiveName(value); return *this;} 66 67 /** 68 * <p>The name for the archive to create.</p> 69 */ WithArchiveName(Aws::String && value)70 inline CreateArchiveRequest& WithArchiveName(Aws::String&& value) { SetArchiveName(std::move(value)); return *this;} 71 72 /** 73 * <p>The name for the archive to create.</p> 74 */ WithArchiveName(const char * value)75 inline CreateArchiveRequest& WithArchiveName(const char* value) { SetArchiveName(value); return *this;} 76 77 78 /** 79 * <p>The ARN of the event bus that sends events to the archive.</p> 80 */ GetEventSourceArn()81 inline const Aws::String& GetEventSourceArn() const{ return m_eventSourceArn; } 82 83 /** 84 * <p>The ARN of the event bus that sends events to the archive.</p> 85 */ EventSourceArnHasBeenSet()86 inline bool EventSourceArnHasBeenSet() const { return m_eventSourceArnHasBeenSet; } 87 88 /** 89 * <p>The ARN of the event bus that sends events to the archive.</p> 90 */ SetEventSourceArn(const Aws::String & value)91 inline void SetEventSourceArn(const Aws::String& value) { m_eventSourceArnHasBeenSet = true; m_eventSourceArn = value; } 92 93 /** 94 * <p>The ARN of the event bus that sends events to the archive.</p> 95 */ SetEventSourceArn(Aws::String && value)96 inline void SetEventSourceArn(Aws::String&& value) { m_eventSourceArnHasBeenSet = true; m_eventSourceArn = std::move(value); } 97 98 /** 99 * <p>The ARN of the event bus that sends events to the archive.</p> 100 */ SetEventSourceArn(const char * value)101 inline void SetEventSourceArn(const char* value) { m_eventSourceArnHasBeenSet = true; m_eventSourceArn.assign(value); } 102 103 /** 104 * <p>The ARN of the event bus that sends events to the archive.</p> 105 */ WithEventSourceArn(const Aws::String & value)106 inline CreateArchiveRequest& WithEventSourceArn(const Aws::String& value) { SetEventSourceArn(value); return *this;} 107 108 /** 109 * <p>The ARN of the event bus that sends events to the archive.</p> 110 */ WithEventSourceArn(Aws::String && value)111 inline CreateArchiveRequest& WithEventSourceArn(Aws::String&& value) { SetEventSourceArn(std::move(value)); return *this;} 112 113 /** 114 * <p>The ARN of the event bus that sends events to the archive.</p> 115 */ WithEventSourceArn(const char * value)116 inline CreateArchiveRequest& WithEventSourceArn(const char* value) { SetEventSourceArn(value); return *this;} 117 118 119 /** 120 * <p>A description for the archive.</p> 121 */ GetDescription()122 inline const Aws::String& GetDescription() const{ return m_description; } 123 124 /** 125 * <p>A description for the archive.</p> 126 */ DescriptionHasBeenSet()127 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } 128 129 /** 130 * <p>A description for the archive.</p> 131 */ SetDescription(const Aws::String & value)132 inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } 133 134 /** 135 * <p>A description for the archive.</p> 136 */ SetDescription(Aws::String && value)137 inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } 138 139 /** 140 * <p>A description for the archive.</p> 141 */ SetDescription(const char * value)142 inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } 143 144 /** 145 * <p>A description for the archive.</p> 146 */ WithDescription(const Aws::String & value)147 inline CreateArchiveRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} 148 149 /** 150 * <p>A description for the archive.</p> 151 */ WithDescription(Aws::String && value)152 inline CreateArchiveRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} 153 154 /** 155 * <p>A description for the archive.</p> 156 */ WithDescription(const char * value)157 inline CreateArchiveRequest& WithDescription(const char* value) { SetDescription(value); return *this;} 158 159 160 /** 161 * <p>An event pattern to use to filter events sent to the archive.</p> 162 */ GetEventPattern()163 inline const Aws::String& GetEventPattern() const{ return m_eventPattern; } 164 165 /** 166 * <p>An event pattern to use to filter events sent to the archive.</p> 167 */ EventPatternHasBeenSet()168 inline bool EventPatternHasBeenSet() const { return m_eventPatternHasBeenSet; } 169 170 /** 171 * <p>An event pattern to use to filter events sent to the archive.</p> 172 */ SetEventPattern(const Aws::String & value)173 inline void SetEventPattern(const Aws::String& value) { m_eventPatternHasBeenSet = true; m_eventPattern = value; } 174 175 /** 176 * <p>An event pattern to use to filter events sent to the archive.</p> 177 */ SetEventPattern(Aws::String && value)178 inline void SetEventPattern(Aws::String&& value) { m_eventPatternHasBeenSet = true; m_eventPattern = std::move(value); } 179 180 /** 181 * <p>An event pattern to use to filter events sent to the archive.</p> 182 */ SetEventPattern(const char * value)183 inline void SetEventPattern(const char* value) { m_eventPatternHasBeenSet = true; m_eventPattern.assign(value); } 184 185 /** 186 * <p>An event pattern to use to filter events sent to the archive.</p> 187 */ WithEventPattern(const Aws::String & value)188 inline CreateArchiveRequest& WithEventPattern(const Aws::String& value) { SetEventPattern(value); return *this;} 189 190 /** 191 * <p>An event pattern to use to filter events sent to the archive.</p> 192 */ WithEventPattern(Aws::String && value)193 inline CreateArchiveRequest& WithEventPattern(Aws::String&& value) { SetEventPattern(std::move(value)); return *this;} 194 195 /** 196 * <p>An event pattern to use to filter events sent to the archive.</p> 197 */ WithEventPattern(const char * value)198 inline CreateArchiveRequest& WithEventPattern(const char* value) { SetEventPattern(value); return *this;} 199 200 201 /** 202 * <p>The number of days to retain events for. Default value is 0. If set to 0, 203 * events are retained indefinitely</p> 204 */ GetRetentionDays()205 inline int GetRetentionDays() const{ return m_retentionDays; } 206 207 /** 208 * <p>The number of days to retain events for. Default value is 0. If set to 0, 209 * events are retained indefinitely</p> 210 */ RetentionDaysHasBeenSet()211 inline bool RetentionDaysHasBeenSet() const { return m_retentionDaysHasBeenSet; } 212 213 /** 214 * <p>The number of days to retain events for. Default value is 0. If set to 0, 215 * events are retained indefinitely</p> 216 */ SetRetentionDays(int value)217 inline void SetRetentionDays(int value) { m_retentionDaysHasBeenSet = true; m_retentionDays = value; } 218 219 /** 220 * <p>The number of days to retain events for. Default value is 0. If set to 0, 221 * events are retained indefinitely</p> 222 */ WithRetentionDays(int value)223 inline CreateArchiveRequest& WithRetentionDays(int value) { SetRetentionDays(value); return *this;} 224 225 private: 226 227 Aws::String m_archiveName; 228 bool m_archiveNameHasBeenSet; 229 230 Aws::String m_eventSourceArn; 231 bool m_eventSourceArnHasBeenSet; 232 233 Aws::String m_description; 234 bool m_descriptionHasBeenSet; 235 236 Aws::String m_eventPattern; 237 bool m_eventPatternHasBeenSet; 238 239 int m_retentionDays; 240 bool m_retentionDaysHasBeenSet; 241 }; 242 243 } // namespace Model 244 } // namespace EventBridge 245 } // namespace Aws 246