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/ec2/EC2_EXPORTS.h> 8 #include <aws/ec2/EC2Request.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <aws/core/utils/memory/stl/AWSVector.h> 11 #include <aws/ec2/model/Filter.h> 12 #include <utility> 13 14 namespace Aws 15 { 16 namespace EC2 17 { 18 namespace Model 19 { 20 21 /** 22 */ 23 class AWS_EC2_API ExportTransitGatewayRoutesRequest : public EC2Request 24 { 25 public: 26 ExportTransitGatewayRoutesRequest(); 27 28 // Service request name is the Operation name which will send this request out, 29 // each operation should has unique request name, so that we can get operation's name from this request. 30 // Note: this is not true for response, multiple operations may have the same response name, 31 // so we can not get operation's name from response. GetServiceRequestName()32 inline virtual const char* GetServiceRequestName() const override { return "ExportTransitGatewayRoutes"; } 33 34 Aws::String SerializePayload() const override; 35 36 protected: 37 void DumpBodyToUrl(Aws::Http::URI& uri ) const override; 38 39 public: 40 41 /** 42 * <p>The ID of the route table.</p> 43 */ GetTransitGatewayRouteTableId()44 inline const Aws::String& GetTransitGatewayRouteTableId() const{ return m_transitGatewayRouteTableId; } 45 46 /** 47 * <p>The ID of the route table.</p> 48 */ TransitGatewayRouteTableIdHasBeenSet()49 inline bool TransitGatewayRouteTableIdHasBeenSet() const { return m_transitGatewayRouteTableIdHasBeenSet; } 50 51 /** 52 * <p>The ID of the route table.</p> 53 */ SetTransitGatewayRouteTableId(const Aws::String & value)54 inline void SetTransitGatewayRouteTableId(const Aws::String& value) { m_transitGatewayRouteTableIdHasBeenSet = true; m_transitGatewayRouteTableId = value; } 55 56 /** 57 * <p>The ID of the route table.</p> 58 */ SetTransitGatewayRouteTableId(Aws::String && value)59 inline void SetTransitGatewayRouteTableId(Aws::String&& value) { m_transitGatewayRouteTableIdHasBeenSet = true; m_transitGatewayRouteTableId = std::move(value); } 60 61 /** 62 * <p>The ID of the route table.</p> 63 */ SetTransitGatewayRouteTableId(const char * value)64 inline void SetTransitGatewayRouteTableId(const char* value) { m_transitGatewayRouteTableIdHasBeenSet = true; m_transitGatewayRouteTableId.assign(value); } 65 66 /** 67 * <p>The ID of the route table.</p> 68 */ WithTransitGatewayRouteTableId(const Aws::String & value)69 inline ExportTransitGatewayRoutesRequest& WithTransitGatewayRouteTableId(const Aws::String& value) { SetTransitGatewayRouteTableId(value); return *this;} 70 71 /** 72 * <p>The ID of the route table.</p> 73 */ WithTransitGatewayRouteTableId(Aws::String && value)74 inline ExportTransitGatewayRoutesRequest& WithTransitGatewayRouteTableId(Aws::String&& value) { SetTransitGatewayRouteTableId(std::move(value)); return *this;} 75 76 /** 77 * <p>The ID of the route table.</p> 78 */ WithTransitGatewayRouteTableId(const char * value)79 inline ExportTransitGatewayRoutesRequest& WithTransitGatewayRouteTableId(const char* value) { SetTransitGatewayRouteTableId(value); return *this;} 80 81 82 /** 83 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 84 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 85 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 86 * resource id of the transit gateway attachment.</p> </li> <li> <p> 87 * <code>route-search.exact-match</code> - The exact match of the specified 88 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 89 * longest prefix that matches the route.</p> </li> <li> <p> 90 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 91 * the specified CIDR filter.</p> </li> <li> <p> 92 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 93 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 94 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 95 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 96 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 97 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 98 * range.</p> </li> <li> <p> <code>type</code> - The type of route 99 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 100 */ GetFilters()101 inline const Aws::Vector<Filter>& GetFilters() const{ return m_filters; } 102 103 /** 104 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 105 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 106 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 107 * resource id of the transit gateway attachment.</p> </li> <li> <p> 108 * <code>route-search.exact-match</code> - The exact match of the specified 109 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 110 * longest prefix that matches the route.</p> </li> <li> <p> 111 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 112 * the specified CIDR filter.</p> </li> <li> <p> 113 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 114 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 115 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 116 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 117 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 118 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 119 * range.</p> </li> <li> <p> <code>type</code> - The type of route 120 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 121 */ FiltersHasBeenSet()122 inline bool FiltersHasBeenSet() const { return m_filtersHasBeenSet; } 123 124 /** 125 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 126 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 127 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 128 * resource id of the transit gateway attachment.</p> </li> <li> <p> 129 * <code>route-search.exact-match</code> - The exact match of the specified 130 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 131 * longest prefix that matches the route.</p> </li> <li> <p> 132 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 133 * the specified CIDR filter.</p> </li> <li> <p> 134 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 135 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 136 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 137 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 138 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 139 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 140 * range.</p> </li> <li> <p> <code>type</code> - The type of route 141 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 142 */ SetFilters(const Aws::Vector<Filter> & value)143 inline void SetFilters(const Aws::Vector<Filter>& value) { m_filtersHasBeenSet = true; m_filters = value; } 144 145 /** 146 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 147 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 148 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 149 * resource id of the transit gateway attachment.</p> </li> <li> <p> 150 * <code>route-search.exact-match</code> - The exact match of the specified 151 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 152 * longest prefix that matches the route.</p> </li> <li> <p> 153 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 154 * the specified CIDR filter.</p> </li> <li> <p> 155 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 156 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 157 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 158 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 159 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 160 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 161 * range.</p> </li> <li> <p> <code>type</code> - The type of route 162 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 163 */ SetFilters(Aws::Vector<Filter> && value)164 inline void SetFilters(Aws::Vector<Filter>&& value) { m_filtersHasBeenSet = true; m_filters = std::move(value); } 165 166 /** 167 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 168 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 169 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 170 * resource id of the transit gateway attachment.</p> </li> <li> <p> 171 * <code>route-search.exact-match</code> - The exact match of the specified 172 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 173 * longest prefix that matches the route.</p> </li> <li> <p> 174 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 175 * the specified CIDR filter.</p> </li> <li> <p> 176 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 177 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 178 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 179 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 180 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 181 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 182 * range.</p> </li> <li> <p> <code>type</code> - The type of route 183 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 184 */ WithFilters(const Aws::Vector<Filter> & value)185 inline ExportTransitGatewayRoutesRequest& WithFilters(const Aws::Vector<Filter>& value) { SetFilters(value); return *this;} 186 187 /** 188 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 189 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 190 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 191 * resource id of the transit gateway attachment.</p> </li> <li> <p> 192 * <code>route-search.exact-match</code> - The exact match of the specified 193 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 194 * longest prefix that matches the route.</p> </li> <li> <p> 195 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 196 * the specified CIDR filter.</p> </li> <li> <p> 197 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 198 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 199 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 200 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 201 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 202 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 203 * range.</p> </li> <li> <p> <code>type</code> - The type of route 204 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 205 */ WithFilters(Aws::Vector<Filter> && value)206 inline ExportTransitGatewayRoutesRequest& WithFilters(Aws::Vector<Filter>&& value) { SetFilters(std::move(value)); return *this;} 207 208 /** 209 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 210 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 211 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 212 * resource id of the transit gateway attachment.</p> </li> <li> <p> 213 * <code>route-search.exact-match</code> - The exact match of the specified 214 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 215 * longest prefix that matches the route.</p> </li> <li> <p> 216 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 217 * the specified CIDR filter.</p> </li> <li> <p> 218 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 219 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 220 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 221 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 222 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 223 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 224 * range.</p> </li> <li> <p> <code>type</code> - The type of route 225 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 226 */ AddFilters(const Filter & value)227 inline ExportTransitGatewayRoutesRequest& AddFilters(const Filter& value) { m_filtersHasBeenSet = true; m_filters.push_back(value); return *this; } 228 229 /** 230 * <p>One or more filters. The possible values are:</p> <ul> <li> <p> 231 * <code>attachment.transit-gateway-attachment-id</code> - The id of the transit 232 * gateway attachment.</p> </li> <li> <p> <code>attachment.resource-id</code> - The 233 * resource id of the transit gateway attachment.</p> </li> <li> <p> 234 * <code>route-search.exact-match</code> - The exact match of the specified 235 * filter.</p> </li> <li> <p> <code>route-search.longest-prefix-match</code> - The 236 * longest prefix that matches the route.</p> </li> <li> <p> 237 * <code>route-search.subnet-of-match</code> - The routes with a subnet that match 238 * the specified CIDR filter.</p> </li> <li> <p> 239 * <code>route-search.supernet-of-match</code> - The routes with a CIDR that 240 * encompass the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 241 * routes in your route table and you specify supernet-of-match as 10.0.1.0/30, 242 * then the result returns 10.0.1.0/29.</p> </li> <li> <p> <code>state</code> - The 243 * state of the route (<code>active</code> | <code>blackhole</code>).</p> </li> 244 * <li> <p> <code>transit-gateway-route-destination-cidr-block</code> - The CIDR 245 * range.</p> </li> <li> <p> <code>type</code> - The type of route 246 * (<code>propagated</code> | <code>static</code>).</p> </li> </ul> 247 */ AddFilters(Filter && value)248 inline ExportTransitGatewayRoutesRequest& AddFilters(Filter&& value) { m_filtersHasBeenSet = true; m_filters.push_back(std::move(value)); return *this; } 249 250 251 /** 252 * <p>The name of the S3 bucket.</p> 253 */ GetS3Bucket()254 inline const Aws::String& GetS3Bucket() const{ return m_s3Bucket; } 255 256 /** 257 * <p>The name of the S3 bucket.</p> 258 */ S3BucketHasBeenSet()259 inline bool S3BucketHasBeenSet() const { return m_s3BucketHasBeenSet; } 260 261 /** 262 * <p>The name of the S3 bucket.</p> 263 */ SetS3Bucket(const Aws::String & value)264 inline void SetS3Bucket(const Aws::String& value) { m_s3BucketHasBeenSet = true; m_s3Bucket = value; } 265 266 /** 267 * <p>The name of the S3 bucket.</p> 268 */ SetS3Bucket(Aws::String && value)269 inline void SetS3Bucket(Aws::String&& value) { m_s3BucketHasBeenSet = true; m_s3Bucket = std::move(value); } 270 271 /** 272 * <p>The name of the S3 bucket.</p> 273 */ SetS3Bucket(const char * value)274 inline void SetS3Bucket(const char* value) { m_s3BucketHasBeenSet = true; m_s3Bucket.assign(value); } 275 276 /** 277 * <p>The name of the S3 bucket.</p> 278 */ WithS3Bucket(const Aws::String & value)279 inline ExportTransitGatewayRoutesRequest& WithS3Bucket(const Aws::String& value) { SetS3Bucket(value); return *this;} 280 281 /** 282 * <p>The name of the S3 bucket.</p> 283 */ WithS3Bucket(Aws::String && value)284 inline ExportTransitGatewayRoutesRequest& WithS3Bucket(Aws::String&& value) { SetS3Bucket(std::move(value)); return *this;} 285 286 /** 287 * <p>The name of the S3 bucket.</p> 288 */ WithS3Bucket(const char * value)289 inline ExportTransitGatewayRoutesRequest& WithS3Bucket(const char* value) { SetS3Bucket(value); return *this;} 290 291 292 /** 293 * <p>Checks whether you have the required permissions for the action, without 294 * actually making the request, and provides an error response. If you have the 295 * required permissions, the error response is <code>DryRunOperation</code>. 296 * Otherwise, it is <code>UnauthorizedOperation</code>.</p> 297 */ GetDryRun()298 inline bool GetDryRun() const{ return m_dryRun; } 299 300 /** 301 * <p>Checks whether you have the required permissions for the action, without 302 * actually making the request, and provides an error response. If you have the 303 * required permissions, the error response is <code>DryRunOperation</code>. 304 * Otherwise, it is <code>UnauthorizedOperation</code>.</p> 305 */ DryRunHasBeenSet()306 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; } 307 308 /** 309 * <p>Checks whether you have the required permissions for the action, without 310 * actually making the request, and provides an error response. If you have the 311 * required permissions, the error response is <code>DryRunOperation</code>. 312 * Otherwise, it is <code>UnauthorizedOperation</code>.</p> 313 */ SetDryRun(bool value)314 inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; } 315 316 /** 317 * <p>Checks whether you have the required permissions for the action, without 318 * actually making the request, and provides an error response. If you have the 319 * required permissions, the error response is <code>DryRunOperation</code>. 320 * Otherwise, it is <code>UnauthorizedOperation</code>.</p> 321 */ WithDryRun(bool value)322 inline ExportTransitGatewayRoutesRequest& WithDryRun(bool value) { SetDryRun(value); return *this;} 323 324 private: 325 326 Aws::String m_transitGatewayRouteTableId; 327 bool m_transitGatewayRouteTableIdHasBeenSet; 328 329 Aws::Vector<Filter> m_filters; 330 bool m_filtersHasBeenSet; 331 332 Aws::String m_s3Bucket; 333 bool m_s3BucketHasBeenSet; 334 335 bool m_dryRun; 336 bool m_dryRunHasBeenSet; 337 }; 338 339 } // namespace Model 340 } // namespace EC2 341 } // namespace Aws 342