Skip to content

Commit ee7ba8d

Browse files
Add polymorph generated code
1 parent 6bc3da1 commit ee7ba8d

File tree

8 files changed

+354
-26
lines changed

8 files changed

+354
-26
lines changed

DynamoDbEncryption/runtimes/net/Generated/DynamoDbEncryption/DynamoDbEncryption.cs

+7
Original file line numberDiff line numberDiff line change
@@ -33,5 +33,12 @@ public AWS.Cryptography.DbEncryptionSDK.DynamoDb.CreateDynamoDbEncryptionBranchK
3333
if (result.is_Failure) throw TypeConversion.FromDafny_CommonError(result.dtor_error);
3434
return TypeConversion.FromDafny_N3_aws__N12_cryptography__N15_dbEncryptionSdk__N8_dynamoDb__S49_CreateDynamoDbEncryptionBranchKeyIdSupplierOutput(result.dtor_value);
3535
}
36+
public AWS.Cryptography.DbEncryptionSDK.DynamoDb.GetEncryptedDataKeyDescriptionOutput GetEncryptedDataKeyDescription(AWS.Cryptography.DbEncryptionSDK.DynamoDb.GetEncryptedDataKeyDescriptionInput input)
37+
{
38+
software.amazon.cryptography.dbencryptionsdk.dynamodb.internaldafny.types._IGetEncryptedDataKeyDescriptionInput internalInput = TypeConversion.ToDafny_N3_aws__N12_cryptography__N15_dbEncryptionSdk__N8_dynamoDb__S35_GetEncryptedDataKeyDescriptionInput(input);
39+
Wrappers_Compile._IResult<software.amazon.cryptography.dbencryptionsdk.dynamodb.internaldafny.types._IGetEncryptedDataKeyDescriptionOutput, software.amazon.cryptography.dbencryptionsdk.dynamodb.internaldafny.types._IError> result = _impl.GetEncryptedDataKeyDescription(internalInput);
40+
if (result.is_Failure) throw TypeConversion.FromDafny_CommonError(result.dtor_error);
41+
return TypeConversion.FromDafny_N3_aws__N12_cryptography__N15_dbEncryptionSdk__N8_dynamoDb__S36_GetEncryptedDataKeyDescriptionOutput(result.dtor_value);
42+
}
3643
}
3744
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
2+
// SPDX-License-Identifier: Apache-2.0
3+
// Do not modify this file. This file is machine generated, and any changes to it will be overwritten.
4+
using System;
5+
using AWS.Cryptography.DbEncryptionSDK.DynamoDb;
6+
namespace AWS.Cryptography.DbEncryptionSDK.DynamoDb
7+
{
8+
public class EncryptedDataKeyDescriptionOutput
9+
{
10+
private string _keyProviderId;
11+
private string _keyProviderInfo;
12+
private string _branchKeyId;
13+
private string _branchKeyVersion;
14+
public string KeyProviderId
15+
{
16+
get { return this._keyProviderId; }
17+
set { this._keyProviderId = value; }
18+
}
19+
public bool IsSetKeyProviderId()
20+
{
21+
return this._keyProviderId != null;
22+
}
23+
public string KeyProviderInfo
24+
{
25+
get { return this._keyProviderInfo; }
26+
set { this._keyProviderInfo = value; }
27+
}
28+
public bool IsSetKeyProviderInfo()
29+
{
30+
return this._keyProviderInfo != null;
31+
}
32+
public string BranchKeyId
33+
{
34+
get { return this._branchKeyId; }
35+
set { this._branchKeyId = value; }
36+
}
37+
public bool IsSetBranchKeyId()
38+
{
39+
return this._branchKeyId != null;
40+
}
41+
public string BranchKeyVersion
42+
{
43+
get { return this._branchKeyVersion; }
44+
set { this._branchKeyVersion = value; }
45+
}
46+
public bool IsSetBranchKeyVersion()
47+
{
48+
return this._branchKeyVersion != null;
49+
}
50+
public void Validate()
51+
{
52+
if (!IsSetKeyProviderId()) throw new System.ArgumentException("Missing value for required property 'KeyProviderId'");
53+
54+
}
55+
}
56+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
2+
// SPDX-License-Identifier: Apache-2.0
3+
// Do not modify this file. This file is machine generated, and any changes to it will be overwritten.
4+
using System;
5+
using AWS.Cryptography.DbEncryptionSDK.DynamoDb;
6+
namespace AWS.Cryptography.DbEncryptionSDK.DynamoDb
7+
{
8+
public class GetEncryptedDataKeyDescriptionInput
9+
{
10+
private AWS.Cryptography.DbEncryptionSDK.DynamoDb.GetEncryptedDataKeyDescriptionUnion _input;
11+
public AWS.Cryptography.DbEncryptionSDK.DynamoDb.GetEncryptedDataKeyDescriptionUnion Input
12+
{
13+
get { return this._input; }
14+
set { this._input = value; }
15+
}
16+
public bool IsSetInput()
17+
{
18+
return this._input != null;
19+
}
20+
public void Validate()
21+
{
22+
if (!IsSetInput()) throw new System.ArgumentException("Missing value for required property 'Input'");
23+
24+
}
25+
}
26+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
2+
// SPDX-License-Identifier: Apache-2.0
3+
// Do not modify this file. This file is machine generated, and any changes to it will be overwritten.
4+
using System;
5+
using AWS.Cryptography.DbEncryptionSDK.DynamoDb;
6+
namespace AWS.Cryptography.DbEncryptionSDK.DynamoDb
7+
{
8+
public class GetEncryptedDataKeyDescriptionOutput
9+
{
10+
private System.Collections.Generic.List<AWS.Cryptography.DbEncryptionSDK.DynamoDb.EncryptedDataKeyDescriptionOutput> _encryptedDataKeyDescriptionOutput;
11+
public System.Collections.Generic.List<AWS.Cryptography.DbEncryptionSDK.DynamoDb.EncryptedDataKeyDescriptionOutput> EncryptedDataKeyDescriptionOutput
12+
{
13+
get { return this._encryptedDataKeyDescriptionOutput; }
14+
set { this._encryptedDataKeyDescriptionOutput = value; }
15+
}
16+
public bool IsSetEncryptedDataKeyDescriptionOutput()
17+
{
18+
return this._encryptedDataKeyDescriptionOutput != null;
19+
}
20+
public void Validate()
21+
{
22+
if (!IsSetEncryptedDataKeyDescriptionOutput()) throw new System.ArgumentException("Missing value for required property 'EncryptedDataKeyDescriptionOutput'");
23+
24+
}
25+
}
26+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
2+
// SPDX-License-Identifier: Apache-2.0
3+
// Do not modify this file. This file is machine generated, and any changes to it will be overwritten.
4+
using System;
5+
using AWS.Cryptography.DbEncryptionSDK.DynamoDb;
6+
namespace AWS.Cryptography.DbEncryptionSDK.DynamoDb
7+
{
8+
public class GetEncryptedDataKeyDescriptionUnion
9+
{
10+
private System.IO.MemoryStream _header;
11+
private System.Collections.Generic.Dictionary<string, Amazon.DynamoDBv2.Model.AttributeValue> _plaintextItem;
12+
public System.IO.MemoryStream Header
13+
{
14+
get { return this._header; }
15+
set { this._header = value; }
16+
}
17+
public bool IsSetHeader()
18+
{
19+
return this._header != null;
20+
}
21+
public System.Collections.Generic.Dictionary<string, Amazon.DynamoDBv2.Model.AttributeValue> PlaintextItem
22+
{
23+
get { return this._plaintextItem; }
24+
set { this._plaintextItem = value; }
25+
}
26+
public bool IsSetPlaintextItem()
27+
{
28+
return this._plaintextItem != null;
29+
}
30+
public void Validate()
31+
{
32+
var numberOfPropertiesSet = Convert.ToUInt16(IsSetHeader()) +
33+
Convert.ToUInt16(IsSetPlaintextItem());
34+
if (numberOfPropertiesSet == 0) throw new System.ArgumentException("No union value set");
35+
36+
if (numberOfPropertiesSet > 1) throw new System.ArgumentException("Multiple union values set");
37+
38+
}
39+
}
40+
}

0 commit comments

Comments
 (0)