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/license-manager/LicenseManager_EXPORTS.h>
8 #include <aws/license-manager/LicenseManagerRequest.h>
9 #include <aws/core/utils/memory/stl/AWSString.h>
10 #include <aws/core/utils/memory/stl/AWSVector.h>
11 #include <aws/license-manager/model/DigitalSignatureMethod.h>
12 #include <aws/license-manager/model/EntitlementData.h>
13 #include <aws/license-manager/model/Metadata.h>
14 #include <utility>
15 
16 namespace Aws
17 {
18 namespace LicenseManager
19 {
20 namespace Model
21 {
22 
23   /**
24    */
25   class AWS_LICENSEMANAGER_API CheckoutBorrowLicenseRequest : public LicenseManagerRequest
26   {
27   public:
28     CheckoutBorrowLicenseRequest();
29 
30     // Service request name is the Operation name which will send this request out,
31     // each operation should has unique request name, so that we can get operation's name from this request.
32     // Note: this is not true for response, multiple operations may have the same response name,
33     // so we can not get operation's name from response.
GetServiceRequestName()34     inline virtual const char* GetServiceRequestName() const override { return "CheckoutBorrowLicense"; }
35 
36     Aws::String SerializePayload() const override;
37 
38     Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
39 
40 
41     /**
42      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
43      * consumption configuration.</p>
44      */
GetLicenseArn()45     inline const Aws::String& GetLicenseArn() const{ return m_licenseArn; }
46 
47     /**
48      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
49      * consumption configuration.</p>
50      */
LicenseArnHasBeenSet()51     inline bool LicenseArnHasBeenSet() const { return m_licenseArnHasBeenSet; }
52 
53     /**
54      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
55      * consumption configuration.</p>
56      */
SetLicenseArn(const Aws::String & value)57     inline void SetLicenseArn(const Aws::String& value) { m_licenseArnHasBeenSet = true; m_licenseArn = value; }
58 
59     /**
60      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
61      * consumption configuration.</p>
62      */
SetLicenseArn(Aws::String && value)63     inline void SetLicenseArn(Aws::String&& value) { m_licenseArnHasBeenSet = true; m_licenseArn = std::move(value); }
64 
65     /**
66      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
67      * consumption configuration.</p>
68      */
SetLicenseArn(const char * value)69     inline void SetLicenseArn(const char* value) { m_licenseArnHasBeenSet = true; m_licenseArn.assign(value); }
70 
71     /**
72      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
73      * consumption configuration.</p>
74      */
WithLicenseArn(const Aws::String & value)75     inline CheckoutBorrowLicenseRequest& WithLicenseArn(const Aws::String& value) { SetLicenseArn(value); return *this;}
76 
77     /**
78      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
79      * consumption configuration.</p>
80      */
WithLicenseArn(Aws::String && value)81     inline CheckoutBorrowLicenseRequest& WithLicenseArn(Aws::String&& value) { SetLicenseArn(std::move(value)); return *this;}
82 
83     /**
84      * <p>Amazon Resource Name (ARN) of the license. The license must use the borrow
85      * consumption configuration.</p>
86      */
WithLicenseArn(const char * value)87     inline CheckoutBorrowLicenseRequest& WithLicenseArn(const char* value) { SetLicenseArn(value); return *this;}
88 
89 
90     /**
91      * <p>License entitlements. Partial checkouts are not supported.</p>
92      */
GetEntitlements()93     inline const Aws::Vector<EntitlementData>& GetEntitlements() const{ return m_entitlements; }
94 
95     /**
96      * <p>License entitlements. Partial checkouts are not supported.</p>
97      */
EntitlementsHasBeenSet()98     inline bool EntitlementsHasBeenSet() const { return m_entitlementsHasBeenSet; }
99 
100     /**
101      * <p>License entitlements. Partial checkouts are not supported.</p>
102      */
SetEntitlements(const Aws::Vector<EntitlementData> & value)103     inline void SetEntitlements(const Aws::Vector<EntitlementData>& value) { m_entitlementsHasBeenSet = true; m_entitlements = value; }
104 
105     /**
106      * <p>License entitlements. Partial checkouts are not supported.</p>
107      */
SetEntitlements(Aws::Vector<EntitlementData> && value)108     inline void SetEntitlements(Aws::Vector<EntitlementData>&& value) { m_entitlementsHasBeenSet = true; m_entitlements = std::move(value); }
109 
110     /**
111      * <p>License entitlements. Partial checkouts are not supported.</p>
112      */
WithEntitlements(const Aws::Vector<EntitlementData> & value)113     inline CheckoutBorrowLicenseRequest& WithEntitlements(const Aws::Vector<EntitlementData>& value) { SetEntitlements(value); return *this;}
114 
115     /**
116      * <p>License entitlements. Partial checkouts are not supported.</p>
117      */
WithEntitlements(Aws::Vector<EntitlementData> && value)118     inline CheckoutBorrowLicenseRequest& WithEntitlements(Aws::Vector<EntitlementData>&& value) { SetEntitlements(std::move(value)); return *this;}
119 
120     /**
121      * <p>License entitlements. Partial checkouts are not supported.</p>
122      */
AddEntitlements(const EntitlementData & value)123     inline CheckoutBorrowLicenseRequest& AddEntitlements(const EntitlementData& value) { m_entitlementsHasBeenSet = true; m_entitlements.push_back(value); return *this; }
124 
125     /**
126      * <p>License entitlements. Partial checkouts are not supported.</p>
127      */
AddEntitlements(EntitlementData && value)128     inline CheckoutBorrowLicenseRequest& AddEntitlements(EntitlementData&& value) { m_entitlementsHasBeenSet = true; m_entitlements.push_back(std::move(value)); return *this; }
129 
130 
131     /**
132      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
133      * algorithm PS384. For more information, see <a
134      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
135      * Signature with RSASSA-PSS</a>.</p>
136      */
GetDigitalSignatureMethod()137     inline const DigitalSignatureMethod& GetDigitalSignatureMethod() const{ return m_digitalSignatureMethod; }
138 
139     /**
140      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
141      * algorithm PS384. For more information, see <a
142      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
143      * Signature with RSASSA-PSS</a>.</p>
144      */
DigitalSignatureMethodHasBeenSet()145     inline bool DigitalSignatureMethodHasBeenSet() const { return m_digitalSignatureMethodHasBeenSet; }
146 
147     /**
148      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
149      * algorithm PS384. For more information, see <a
150      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
151      * Signature with RSASSA-PSS</a>.</p>
152      */
SetDigitalSignatureMethod(const DigitalSignatureMethod & value)153     inline void SetDigitalSignatureMethod(const DigitalSignatureMethod& value) { m_digitalSignatureMethodHasBeenSet = true; m_digitalSignatureMethod = value; }
154 
155     /**
156      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
157      * algorithm PS384. For more information, see <a
158      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
159      * Signature with RSASSA-PSS</a>.</p>
160      */
SetDigitalSignatureMethod(DigitalSignatureMethod && value)161     inline void SetDigitalSignatureMethod(DigitalSignatureMethod&& value) { m_digitalSignatureMethodHasBeenSet = true; m_digitalSignatureMethod = std::move(value); }
162 
163     /**
164      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
165      * algorithm PS384. For more information, see <a
166      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
167      * Signature with RSASSA-PSS</a>.</p>
168      */
WithDigitalSignatureMethod(const DigitalSignatureMethod & value)169     inline CheckoutBorrowLicenseRequest& WithDigitalSignatureMethod(const DigitalSignatureMethod& value) { SetDigitalSignatureMethod(value); return *this;}
170 
171     /**
172      * <p>Digital signature method. The possible value is JSON Web Signature (JWS)
173      * algorithm PS384. For more information, see <a
174      * href="https://tools.ietf.org/html/rfc7518#section-3.5">RFC 7518 Digital
175      * Signature with RSASSA-PSS</a>.</p>
176      */
WithDigitalSignatureMethod(DigitalSignatureMethod && value)177     inline CheckoutBorrowLicenseRequest& WithDigitalSignatureMethod(DigitalSignatureMethod&& value) { SetDigitalSignatureMethod(std::move(value)); return *this;}
178 
179 
180     /**
181      * <p>Node ID.</p>
182      */
GetNodeId()183     inline const Aws::String& GetNodeId() const{ return m_nodeId; }
184 
185     /**
186      * <p>Node ID.</p>
187      */
NodeIdHasBeenSet()188     inline bool NodeIdHasBeenSet() const { return m_nodeIdHasBeenSet; }
189 
190     /**
191      * <p>Node ID.</p>
192      */
SetNodeId(const Aws::String & value)193     inline void SetNodeId(const Aws::String& value) { m_nodeIdHasBeenSet = true; m_nodeId = value; }
194 
195     /**
196      * <p>Node ID.</p>
197      */
SetNodeId(Aws::String && value)198     inline void SetNodeId(Aws::String&& value) { m_nodeIdHasBeenSet = true; m_nodeId = std::move(value); }
199 
200     /**
201      * <p>Node ID.</p>
202      */
SetNodeId(const char * value)203     inline void SetNodeId(const char* value) { m_nodeIdHasBeenSet = true; m_nodeId.assign(value); }
204 
205     /**
206      * <p>Node ID.</p>
207      */
WithNodeId(const Aws::String & value)208     inline CheckoutBorrowLicenseRequest& WithNodeId(const Aws::String& value) { SetNodeId(value); return *this;}
209 
210     /**
211      * <p>Node ID.</p>
212      */
WithNodeId(Aws::String && value)213     inline CheckoutBorrowLicenseRequest& WithNodeId(Aws::String&& value) { SetNodeId(std::move(value)); return *this;}
214 
215     /**
216      * <p>Node ID.</p>
217      */
WithNodeId(const char * value)218     inline CheckoutBorrowLicenseRequest& WithNodeId(const char* value) { SetNodeId(value); return *this;}
219 
220 
221     /**
222      * <p>Information about constraints.</p>
223      */
GetCheckoutMetadata()224     inline const Aws::Vector<Metadata>& GetCheckoutMetadata() const{ return m_checkoutMetadata; }
225 
226     /**
227      * <p>Information about constraints.</p>
228      */
CheckoutMetadataHasBeenSet()229     inline bool CheckoutMetadataHasBeenSet() const { return m_checkoutMetadataHasBeenSet; }
230 
231     /**
232      * <p>Information about constraints.</p>
233      */
SetCheckoutMetadata(const Aws::Vector<Metadata> & value)234     inline void SetCheckoutMetadata(const Aws::Vector<Metadata>& value) { m_checkoutMetadataHasBeenSet = true; m_checkoutMetadata = value; }
235 
236     /**
237      * <p>Information about constraints.</p>
238      */
SetCheckoutMetadata(Aws::Vector<Metadata> && value)239     inline void SetCheckoutMetadata(Aws::Vector<Metadata>&& value) { m_checkoutMetadataHasBeenSet = true; m_checkoutMetadata = std::move(value); }
240 
241     /**
242      * <p>Information about constraints.</p>
243      */
WithCheckoutMetadata(const Aws::Vector<Metadata> & value)244     inline CheckoutBorrowLicenseRequest& WithCheckoutMetadata(const Aws::Vector<Metadata>& value) { SetCheckoutMetadata(value); return *this;}
245 
246     /**
247      * <p>Information about constraints.</p>
248      */
WithCheckoutMetadata(Aws::Vector<Metadata> && value)249     inline CheckoutBorrowLicenseRequest& WithCheckoutMetadata(Aws::Vector<Metadata>&& value) { SetCheckoutMetadata(std::move(value)); return *this;}
250 
251     /**
252      * <p>Information about constraints.</p>
253      */
AddCheckoutMetadata(const Metadata & value)254     inline CheckoutBorrowLicenseRequest& AddCheckoutMetadata(const Metadata& value) { m_checkoutMetadataHasBeenSet = true; m_checkoutMetadata.push_back(value); return *this; }
255 
256     /**
257      * <p>Information about constraints.</p>
258      */
AddCheckoutMetadata(Metadata && value)259     inline CheckoutBorrowLicenseRequest& AddCheckoutMetadata(Metadata&& value) { m_checkoutMetadataHasBeenSet = true; m_checkoutMetadata.push_back(std::move(value)); return *this; }
260 
261 
262     /**
263      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
264      * of the request.</p>
265      */
GetClientToken()266     inline const Aws::String& GetClientToken() const{ return m_clientToken; }
267 
268     /**
269      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
270      * of the request.</p>
271      */
ClientTokenHasBeenSet()272     inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
273 
274     /**
275      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
276      * of the request.</p>
277      */
SetClientToken(const Aws::String & value)278     inline void SetClientToken(const Aws::String& value) { m_clientTokenHasBeenSet = true; m_clientToken = value; }
279 
280     /**
281      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
282      * of the request.</p>
283      */
SetClientToken(Aws::String && value)284     inline void SetClientToken(Aws::String&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::move(value); }
285 
286     /**
287      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
288      * of the request.</p>
289      */
SetClientToken(const char * value)290     inline void SetClientToken(const char* value) { m_clientTokenHasBeenSet = true; m_clientToken.assign(value); }
291 
292     /**
293      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
294      * of the request.</p>
295      */
WithClientToken(const Aws::String & value)296     inline CheckoutBorrowLicenseRequest& WithClientToken(const Aws::String& value) { SetClientToken(value); return *this;}
297 
298     /**
299      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
300      * of the request.</p>
301      */
WithClientToken(Aws::String && value)302     inline CheckoutBorrowLicenseRequest& WithClientToken(Aws::String&& value) { SetClientToken(std::move(value)); return *this;}
303 
304     /**
305      * <p>Unique, case-sensitive identifier that you provide to ensure the idempotency
306      * of the request.</p>
307      */
WithClientToken(const char * value)308     inline CheckoutBorrowLicenseRequest& WithClientToken(const char* value) { SetClientToken(value); return *this;}
309 
310   private:
311 
312     Aws::String m_licenseArn;
313     bool m_licenseArnHasBeenSet;
314 
315     Aws::Vector<EntitlementData> m_entitlements;
316     bool m_entitlementsHasBeenSet;
317 
318     DigitalSignatureMethod m_digitalSignatureMethod;
319     bool m_digitalSignatureMethodHasBeenSet;
320 
321     Aws::String m_nodeId;
322     bool m_nodeIdHasBeenSet;
323 
324     Aws::Vector<Metadata> m_checkoutMetadata;
325     bool m_checkoutMetadataHasBeenSet;
326 
327     Aws::String m_clientToken;
328     bool m_clientTokenHasBeenSet;
329   };
330 
331 } // namespace Model
332 } // namespace LicenseManager
333 } // namespace Aws
334