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/TagSpecification.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 CreateNetworkAclRequest : public EC2Request
24   {
25   public:
26     CreateNetworkAclRequest();
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 "CreateNetworkAcl"; }
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>Checks whether you have the required permissions for the action, without
43      * actually making the request, and provides an error response. If you have the
44      * required permissions, the error response is <code>DryRunOperation</code>.
45      * Otherwise, it is <code>UnauthorizedOperation</code>.</p>
46      */
GetDryRun()47     inline bool GetDryRun() const{ return m_dryRun; }
48 
49     /**
50      * <p>Checks whether you have the required permissions for the action, without
51      * actually making the request, and provides an error response. If you have the
52      * required permissions, the error response is <code>DryRunOperation</code>.
53      * Otherwise, it is <code>UnauthorizedOperation</code>.</p>
54      */
DryRunHasBeenSet()55     inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
56 
57     /**
58      * <p>Checks whether you have the required permissions for the action, without
59      * actually making the request, and provides an error response. If you have the
60      * required permissions, the error response is <code>DryRunOperation</code>.
61      * Otherwise, it is <code>UnauthorizedOperation</code>.</p>
62      */
SetDryRun(bool value)63     inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
64 
65     /**
66      * <p>Checks whether you have the required permissions for the action, without
67      * actually making the request, and provides an error response. If you have the
68      * required permissions, the error response is <code>DryRunOperation</code>.
69      * Otherwise, it is <code>UnauthorizedOperation</code>.</p>
70      */
WithDryRun(bool value)71     inline CreateNetworkAclRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
72 
73 
74     /**
75      * <p>The ID of the VPC.</p>
76      */
GetVpcId()77     inline const Aws::String& GetVpcId() const{ return m_vpcId; }
78 
79     /**
80      * <p>The ID of the VPC.</p>
81      */
VpcIdHasBeenSet()82     inline bool VpcIdHasBeenSet() const { return m_vpcIdHasBeenSet; }
83 
84     /**
85      * <p>The ID of the VPC.</p>
86      */
SetVpcId(const Aws::String & value)87     inline void SetVpcId(const Aws::String& value) { m_vpcIdHasBeenSet = true; m_vpcId = value; }
88 
89     /**
90      * <p>The ID of the VPC.</p>
91      */
SetVpcId(Aws::String && value)92     inline void SetVpcId(Aws::String&& value) { m_vpcIdHasBeenSet = true; m_vpcId = std::move(value); }
93 
94     /**
95      * <p>The ID of the VPC.</p>
96      */
SetVpcId(const char * value)97     inline void SetVpcId(const char* value) { m_vpcIdHasBeenSet = true; m_vpcId.assign(value); }
98 
99     /**
100      * <p>The ID of the VPC.</p>
101      */
WithVpcId(const Aws::String & value)102     inline CreateNetworkAclRequest& WithVpcId(const Aws::String& value) { SetVpcId(value); return *this;}
103 
104     /**
105      * <p>The ID of the VPC.</p>
106      */
WithVpcId(Aws::String && value)107     inline CreateNetworkAclRequest& WithVpcId(Aws::String&& value) { SetVpcId(std::move(value)); return *this;}
108 
109     /**
110      * <p>The ID of the VPC.</p>
111      */
WithVpcId(const char * value)112     inline CreateNetworkAclRequest& WithVpcId(const char* value) { SetVpcId(value); return *this;}
113 
114 
115     /**
116      * <p>The tags to assign to the network ACL.</p>
117      */
GetTagSpecifications()118     inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const{ return m_tagSpecifications; }
119 
120     /**
121      * <p>The tags to assign to the network ACL.</p>
122      */
TagSpecificationsHasBeenSet()123     inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
124 
125     /**
126      * <p>The tags to assign to the network ACL.</p>
127      */
SetTagSpecifications(const Aws::Vector<TagSpecification> & value)128     inline void SetTagSpecifications(const Aws::Vector<TagSpecification>& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = value; }
129 
130     /**
131      * <p>The tags to assign to the network ACL.</p>
132      */
SetTagSpecifications(Aws::Vector<TagSpecification> && value)133     inline void SetTagSpecifications(Aws::Vector<TagSpecification>&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = std::move(value); }
134 
135     /**
136      * <p>The tags to assign to the network ACL.</p>
137      */
WithTagSpecifications(const Aws::Vector<TagSpecification> & value)138     inline CreateNetworkAclRequest& WithTagSpecifications(const Aws::Vector<TagSpecification>& value) { SetTagSpecifications(value); return *this;}
139 
140     /**
141      * <p>The tags to assign to the network ACL.</p>
142      */
WithTagSpecifications(Aws::Vector<TagSpecification> && value)143     inline CreateNetworkAclRequest& WithTagSpecifications(Aws::Vector<TagSpecification>&& value) { SetTagSpecifications(std::move(value)); return *this;}
144 
145     /**
146      * <p>The tags to assign to the network ACL.</p>
147      */
AddTagSpecifications(const TagSpecification & value)148     inline CreateNetworkAclRequest& AddTagSpecifications(const TagSpecification& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.push_back(value); return *this; }
149 
150     /**
151      * <p>The tags to assign to the network ACL.</p>
152      */
AddTagSpecifications(TagSpecification && value)153     inline CreateNetworkAclRequest& AddTagSpecifications(TagSpecification&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.push_back(std::move(value)); return *this; }
154 
155   private:
156 
157     bool m_dryRun;
158     bool m_dryRunHasBeenSet;
159 
160     Aws::String m_vpcId;
161     bool m_vpcIdHasBeenSet;
162 
163     Aws::Vector<TagSpecification> m_tagSpecifications;
164     bool m_tagSpecificationsHasBeenSet;
165   };
166 
167 } // namespace Model
168 } // namespace EC2
169 } // namespace Aws
170