AWS SDK for C++  0.14.3
AWS SDK for C++
CreateKeyRequest.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
16 #include <aws/kms/KMS_EXPORTS.h>
17 #include <aws/kms/KMSRequest.h>
21 
22 namespace Aws
23 {
24 namespace KMS
25 {
26 namespace Model
27 {
28 
32  {
33  public:
35  Aws::String SerializePayload() const override;
36 
37  Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
38 
61  inline const Aws::String& GetPolicy() const{ return m_policy; }
62 
85  inline void SetPolicy(const Aws::String& value) { m_policyHasBeenSet = true; m_policy = value; }
86 
109  inline void SetPolicy(Aws::String&& value) { m_policyHasBeenSet = true; m_policy = value; }
110 
133  inline void SetPolicy(const char* value) { m_policyHasBeenSet = true; m_policy.assign(value); }
134 
157  inline CreateKeyRequest& WithPolicy(const Aws::String& value) { SetPolicy(value); return *this;}
158 
181  inline CreateKeyRequest& WithPolicy(Aws::String&& value) { SetPolicy(value); return *this;}
182 
205  inline CreateKeyRequest& WithPolicy(const char* value) { SetPolicy(value); return *this;}
206 
211  inline const Aws::String& GetDescription() const{ return m_description; }
212 
217  inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; }
218 
223  inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = value; }
224 
229  inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); }
230 
235  inline CreateKeyRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;}
236 
241  inline CreateKeyRequest& WithDescription(Aws::String&& value) { SetDescription(value); return *this;}
242 
247  inline CreateKeyRequest& WithDescription(const char* value) { SetDescription(value); return *this;}
248 
253  inline const KeyUsageType& GetKeyUsage() const{ return m_keyUsage; }
254 
259  inline void SetKeyUsage(const KeyUsageType& value) { m_keyUsageHasBeenSet = true; m_keyUsage = value; }
260 
265  inline void SetKeyUsage(KeyUsageType&& value) { m_keyUsageHasBeenSet = true; m_keyUsage = value; }
266 
271  inline CreateKeyRequest& WithKeyUsage(const KeyUsageType& value) { SetKeyUsage(value); return *this;}
272 
277  inline CreateKeyRequest& WithKeyUsage(KeyUsageType&& value) { SetKeyUsage(value); return *this;}
278 
291  inline const OriginType& GetOrigin() const{ return m_origin; }
292 
305  inline void SetOrigin(const OriginType& value) { m_originHasBeenSet = true; m_origin = value; }
306 
319  inline void SetOrigin(OriginType&& value) { m_originHasBeenSet = true; m_origin = value; }
320 
333  inline CreateKeyRequest& WithOrigin(const OriginType& value) { SetOrigin(value); return *this;}
334 
347  inline CreateKeyRequest& WithOrigin(OriginType&& value) { SetOrigin(value); return *this;}
348 
361  inline bool GetBypassPolicyLockoutSafetyCheck() const{ return m_bypassPolicyLockoutSafetyCheck; }
362 
375  inline void SetBypassPolicyLockoutSafetyCheck(bool value) { m_bypassPolicyLockoutSafetyCheckHasBeenSet = true; m_bypassPolicyLockoutSafetyCheck = value; }
376 
389  inline CreateKeyRequest& WithBypassPolicyLockoutSafetyCheck(bool value) { SetBypassPolicyLockoutSafetyCheck(value); return *this;}
390 
391  private:
392  Aws::String m_policy;
393  bool m_policyHasBeenSet;
394  Aws::String m_description;
395  bool m_descriptionHasBeenSet;
396  KeyUsageType m_keyUsage;
397  bool m_keyUsageHasBeenSet;
398  OriginType m_origin;
399  bool m_originHasBeenSet;
400  bool m_bypassPolicyLockoutSafetyCheck;
401  bool m_bypassPolicyLockoutSafetyCheckHasBeenSet;
402  };
403 
404 } // namespace Model
405 } // namespace KMS
406 } // namespace Aws
CreateKeyRequest & WithOrigin(OriginType &&value)
CreateKeyRequest & WithPolicy(const Aws::String &value)
void SetBypassPolicyLockoutSafetyCheck(bool value)
const KeyUsageType & GetKeyUsage() const
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
Definition: HttpTypes.h:63
void SetPolicy(const Aws::String &value)
CreateKeyRequest & WithKeyUsage(KeyUsageType &&value)
CreateKeyRequest & WithBypassPolicyLockoutSafetyCheck(bool value)
CreateKeyRequest & WithDescription(Aws::String &&value)
void SetPolicy(Aws::String &&value)
CreateKeyRequest & WithDescription(const Aws::String &value)
CreateKeyRequest & WithOrigin(const OriginType &value)
void SetPolicy(const char *value)
void SetKeyUsage(const KeyUsageType &value)
void SetOrigin(OriginType &&value)
CreateKeyRequest & WithKeyUsage(const KeyUsageType &value)
const Aws::String & GetPolicy() const
CreateKeyRequest & WithPolicy(const char *value)
void SetOrigin(const OriginType &value)
CreateKeyRequest & WithPolicy(Aws::String &&value)
void SetDescription(Aws::String &&value)
void SetDescription(const Aws::String &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
CreateKeyRequest & WithDescription(const char *value)
void SetDescription(const char *value)
void SetKeyUsage(KeyUsageType &&value)
#define AWS_KMS_API
Definition: KMS_EXPORTS.h:37
const OriginType & GetOrigin() const
JSON (JavaScript Object Notation).
const Aws::String & GetDescription() const