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/kinesis/Kinesis_EXPORTS.h> 8 #include <aws/kinesis/KinesisRequest.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <aws/kinesis/model/EncryptionType.h> 11 #include <utility> 12 13 namespace Aws 14 { 15 namespace Kinesis 16 { 17 namespace Model 18 { 19 20 /** 21 */ 22 class AWS_KINESIS_API StartStreamEncryptionRequest : public KinesisRequest 23 { 24 public: 25 StartStreamEncryptionRequest(); 26 27 // Service request name is the Operation name which will send this request out, 28 // each operation should has unique request name, so that we can get operation's name from this request. 29 // Note: this is not true for response, multiple operations may have the same response name, 30 // so we can not get operation's name from response. GetServiceRequestName()31 inline virtual const char* GetServiceRequestName() const override { return "StartStreamEncryption"; } 32 33 Aws::String SerializePayload() const override; 34 35 Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; 36 37 38 /** 39 * <p>The name of the stream for which to start encrypting records.</p> 40 */ GetStreamName()41 inline const Aws::String& GetStreamName() const{ return m_streamName; } 42 43 /** 44 * <p>The name of the stream for which to start encrypting records.</p> 45 */ StreamNameHasBeenSet()46 inline bool StreamNameHasBeenSet() const { return m_streamNameHasBeenSet; } 47 48 /** 49 * <p>The name of the stream for which to start encrypting records.</p> 50 */ SetStreamName(const Aws::String & value)51 inline void SetStreamName(const Aws::String& value) { m_streamNameHasBeenSet = true; m_streamName = value; } 52 53 /** 54 * <p>The name of the stream for which to start encrypting records.</p> 55 */ SetStreamName(Aws::String && value)56 inline void SetStreamName(Aws::String&& value) { m_streamNameHasBeenSet = true; m_streamName = std::move(value); } 57 58 /** 59 * <p>The name of the stream for which to start encrypting records.</p> 60 */ SetStreamName(const char * value)61 inline void SetStreamName(const char* value) { m_streamNameHasBeenSet = true; m_streamName.assign(value); } 62 63 /** 64 * <p>The name of the stream for which to start encrypting records.</p> 65 */ WithStreamName(const Aws::String & value)66 inline StartStreamEncryptionRequest& WithStreamName(const Aws::String& value) { SetStreamName(value); return *this;} 67 68 /** 69 * <p>The name of the stream for which to start encrypting records.</p> 70 */ WithStreamName(Aws::String && value)71 inline StartStreamEncryptionRequest& WithStreamName(Aws::String&& value) { SetStreamName(std::move(value)); return *this;} 72 73 /** 74 * <p>The name of the stream for which to start encrypting records.</p> 75 */ WithStreamName(const char * value)76 inline StartStreamEncryptionRequest& WithStreamName(const char* value) { SetStreamName(value); return *this;} 77 78 79 /** 80 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 81 */ GetEncryptionType()82 inline const EncryptionType& GetEncryptionType() const{ return m_encryptionType; } 83 84 /** 85 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 86 */ EncryptionTypeHasBeenSet()87 inline bool EncryptionTypeHasBeenSet() const { return m_encryptionTypeHasBeenSet; } 88 89 /** 90 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 91 */ SetEncryptionType(const EncryptionType & value)92 inline void SetEncryptionType(const EncryptionType& value) { m_encryptionTypeHasBeenSet = true; m_encryptionType = value; } 93 94 /** 95 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 96 */ SetEncryptionType(EncryptionType && value)97 inline void SetEncryptionType(EncryptionType&& value) { m_encryptionTypeHasBeenSet = true; m_encryptionType = std::move(value); } 98 99 /** 100 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 101 */ WithEncryptionType(const EncryptionType & value)102 inline StartStreamEncryptionRequest& WithEncryptionType(const EncryptionType& value) { SetEncryptionType(value); return *this;} 103 104 /** 105 * <p>The encryption type to use. The only valid value is <code>KMS</code>.</p> 106 */ WithEncryptionType(EncryptionType && value)107 inline StartStreamEncryptionRequest& WithEncryptionType(EncryptionType&& value) { SetEncryptionType(std::move(value)); return *this;} 108 109 110 /** 111 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 112 * value can be a globally unique identifier, a fully specified Amazon Resource 113 * Name (ARN) to either an alias or a key, or an alias name prefixed by 114 * "alias/".You can also use a master key owned by Kinesis Data Streams by 115 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 116 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 117 * </p> </li> <li> <p>Alias ARN example: 118 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 119 * <li> <p>Globally unique key ID example: 120 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 121 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 122 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 123 */ GetKeyId()124 inline const Aws::String& GetKeyId() const{ return m_keyId; } 125 126 /** 127 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 128 * value can be a globally unique identifier, a fully specified Amazon Resource 129 * Name (ARN) to either an alias or a key, or an alias name prefixed by 130 * "alias/".You can also use a master key owned by Kinesis Data Streams by 131 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 132 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 133 * </p> </li> <li> <p>Alias ARN example: 134 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 135 * <li> <p>Globally unique key ID example: 136 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 137 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 138 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 139 */ KeyIdHasBeenSet()140 inline bool KeyIdHasBeenSet() const { return m_keyIdHasBeenSet; } 141 142 /** 143 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 144 * value can be a globally unique identifier, a fully specified Amazon Resource 145 * Name (ARN) to either an alias or a key, or an alias name prefixed by 146 * "alias/".You can also use a master key owned by Kinesis Data Streams by 147 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 148 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 149 * </p> </li> <li> <p>Alias ARN example: 150 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 151 * <li> <p>Globally unique key ID example: 152 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 153 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 154 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 155 */ SetKeyId(const Aws::String & value)156 inline void SetKeyId(const Aws::String& value) { m_keyIdHasBeenSet = true; m_keyId = value; } 157 158 /** 159 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 160 * value can be a globally unique identifier, a fully specified Amazon Resource 161 * Name (ARN) to either an alias or a key, or an alias name prefixed by 162 * "alias/".You can also use a master key owned by Kinesis Data Streams by 163 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 164 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 165 * </p> </li> <li> <p>Alias ARN example: 166 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 167 * <li> <p>Globally unique key ID example: 168 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 169 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 170 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 171 */ SetKeyId(Aws::String && value)172 inline void SetKeyId(Aws::String&& value) { m_keyIdHasBeenSet = true; m_keyId = std::move(value); } 173 174 /** 175 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 176 * value can be a globally unique identifier, a fully specified Amazon Resource 177 * Name (ARN) to either an alias or a key, or an alias name prefixed by 178 * "alias/".You can also use a master key owned by Kinesis Data Streams by 179 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 180 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 181 * </p> </li> <li> <p>Alias ARN example: 182 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 183 * <li> <p>Globally unique key ID example: 184 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 185 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 186 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 187 */ SetKeyId(const char * value)188 inline void SetKeyId(const char* value) { m_keyIdHasBeenSet = true; m_keyId.assign(value); } 189 190 /** 191 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 192 * value can be a globally unique identifier, a fully specified Amazon Resource 193 * Name (ARN) to either an alias or a key, or an alias name prefixed by 194 * "alias/".You can also use a master key owned by Kinesis Data Streams by 195 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 196 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 197 * </p> </li> <li> <p>Alias ARN example: 198 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 199 * <li> <p>Globally unique key ID example: 200 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 201 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 202 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 203 */ WithKeyId(const Aws::String & value)204 inline StartStreamEncryptionRequest& WithKeyId(const Aws::String& value) { SetKeyId(value); return *this;} 205 206 /** 207 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 208 * value can be a globally unique identifier, a fully specified Amazon Resource 209 * Name (ARN) to either an alias or a key, or an alias name prefixed by 210 * "alias/".You can also use a master key owned by Kinesis Data Streams by 211 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 212 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 213 * </p> </li> <li> <p>Alias ARN example: 214 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 215 * <li> <p>Globally unique key ID example: 216 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 217 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 218 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 219 */ WithKeyId(Aws::String && value)220 inline StartStreamEncryptionRequest& WithKeyId(Aws::String&& value) { SetKeyId(std::move(value)); return *this;} 221 222 /** 223 * <p>The GUID for the customer-managed AWS KMS key to use for encryption. This 224 * value can be a globally unique identifier, a fully specified Amazon Resource 225 * Name (ARN) to either an alias or a key, or an alias name prefixed by 226 * "alias/".You can also use a master key owned by Kinesis Data Streams by 227 * specifying the alias <code>aws/kinesis</code>.</p> <ul> <li> <p>Key ARN example: 228 * <code>arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012</code> 229 * </p> </li> <li> <p>Alias ARN example: 230 * <code>arn:aws:kms:us-east-1:123456789012:alias/MyAliasName</code> </p> </li> 231 * <li> <p>Globally unique key ID example: 232 * <code>12345678-1234-1234-1234-123456789012</code> </p> </li> <li> <p>Alias name 233 * example: <code>alias/MyAliasName</code> </p> </li> <li> <p>Master key owned by 234 * Kinesis Data Streams: <code>alias/aws/kinesis</code> </p> </li> </ul> 235 */ WithKeyId(const char * value)236 inline StartStreamEncryptionRequest& WithKeyId(const char* value) { SetKeyId(value); return *this;} 237 238 private: 239 240 Aws::String m_streamName; 241 bool m_streamNameHasBeenSet; 242 243 EncryptionType m_encryptionType; 244 bool m_encryptionTypeHasBeenSet; 245 246 Aws::String m_keyId; 247 bool m_keyIdHasBeenSet; 248 }; 249 250 } // namespace Model 251 } // namespace Kinesis 252 } // namespace Aws 253