Skip to content

Commit 8bf0a7b

Browse files
repoly
1 parent a73fbc6 commit 8bf0a7b

File tree

18 files changed

+28
-220
lines changed

18 files changed

+28
-220
lines changed

DynamoDbEncryption/dafny/DynamoDbEncryption/Model/AwsCryptographyDbEncryptionSdkDynamoDbTypes.dfy

+1-1
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,7 @@ module {:extern "software.amazon.cryptography.dbencryptionsdk.dynamodb.internald
476476
// || (!exit(A(I)) && !access(B(I)))
477477
| CollectionOfErrors(list: seq<Error>, nameonly message: string)
478478
// The Opaque error, used for native, extern, wrapped or unknown errors
479-
| Opaque(obj: object, alt_text : string := "")
479+
| Opaque(obj: object)
480480
type OpaqueError = e: Error | e.Opaque? witness *
481481
}
482482
abstract module AbstractAwsCryptographyDbEncryptionSdkDynamoDbService

DynamoDbEncryption/dafny/DynamoDbEncryptionTransforms/Model/AwsCryptographyDbEncryptionSdkDynamoDbTransformsTypes.dfy

+1-1
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ module {:extern "software.amazon.cryptography.dbencryptionsdk.dynamodb.transform
728728
// || (!exit(A(I)) && !access(B(I)))
729729
| CollectionOfErrors(list: seq<Error>, nameonly message: string)
730730
// The Opaque error, used for native, extern, wrapped or unknown errors
731-
| Opaque(obj: object, alt_text : string := "")
731+
| Opaque(obj: object)
732732
type OpaqueError = e: Error | e.Opaque? witness *
733733
}
734734
abstract module AbstractAwsCryptographyDbEncryptionSdkDynamoDbTransformsService

DynamoDbEncryption/dafny/DynamoDbItemEncryptor/Model/AwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorTypes.dfy

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ module {:extern "software.amazon.cryptography.dbencryptionsdk.dynamodb.itemencry
159159
// || (!exit(A(I)) && !access(B(I)))
160160
| CollectionOfErrors(list: seq<Error>, nameonly message: string)
161161
// The Opaque error, used for native, extern, wrapped or unknown errors
162-
| Opaque(obj: object, alt_text : string := "")
162+
| Opaque(obj: object)
163163
type OpaqueError = e: Error | e.Opaque? witness *
164164
}
165165
abstract module AbstractAwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorService

DynamoDbEncryption/dafny/StructuredEncryption/Model/AwsCryptographyDbEncryptionSdkStructuredEncryptionTypes.dfy

+1-1
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ module {:extern "software.amazon.cryptography.dbencryptionsdk.structuredencrypti
283283
// || (!exit(A(I)) && !access(B(I)))
284284
| CollectionOfErrors(list: seq<Error>, nameonly message: string)
285285
// The Opaque error, used for native, extern, wrapped or unknown errors
286-
| Opaque(obj: object, alt_text : string := "")
286+
| Opaque(obj: object)
287287
type OpaqueError = e: Error | e.Opaque? witness *
288288
}
289289
abstract module AbstractAwsCryptographyDbEncryptionSdkStructuredEncryptionService

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/ToDafny.java

+2-16
Original file line numberDiff line numberDiff line change
@@ -84,25 +84,11 @@ public static Error Error(RuntimeException nativeValue) {
8484
if (nativeValue instanceof CollectionOfErrors) {
8585
return ToDafny.Error((CollectionOfErrors) nativeValue);
8686
}
87-
return Error.create_Opaque(
88-
nativeValue,
89-
dafny.DafnySequence.asString(
90-
java.util.Objects.nonNull(nativeValue.getMessage())
91-
? nativeValue.getMessage()
92-
: ""
93-
)
94-
);
87+
return Error.create_Opaque(nativeValue);
9588
}
9689

9790
public static Error Error(OpaqueError nativeValue) {
98-
return Error.create_Opaque(
99-
nativeValue.obj(),
100-
dafny.DafnySequence.asString(
101-
java.util.Objects.nonNull(nativeValue.altText())
102-
? nativeValue.altText()
103-
: ""
104-
)
105-
);
91+
return Error.create_Opaque(nativeValue.obj());
10692
}
10793

10894
public static Error Error(CollectionOfErrors nativeValue) {

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/itemencryptor/ToDafny.java

+2-16
Original file line numberDiff line numberDiff line change
@@ -44,25 +44,11 @@ public static Error Error(RuntimeException nativeValue) {
4444
if (nativeValue instanceof CollectionOfErrors) {
4545
return ToDafny.Error((CollectionOfErrors) nativeValue);
4646
}
47-
return Error.create_Opaque(
48-
nativeValue,
49-
dafny.DafnySequence.asString(
50-
java.util.Objects.nonNull(nativeValue.getMessage())
51-
? nativeValue.getMessage()
52-
: ""
53-
)
54-
);
47+
return Error.create_Opaque(nativeValue);
5548
}
5649

5750
public static Error Error(OpaqueError nativeValue) {
58-
return Error.create_Opaque(
59-
nativeValue.obj(),
60-
dafny.DafnySequence.asString(
61-
java.util.Objects.nonNull(nativeValue.altText())
62-
? nativeValue.altText()
63-
: ""
64-
)
65-
);
51+
return Error.create_Opaque(nativeValue.obj());
6652
}
6753

6854
public static Error Error(CollectionOfErrors nativeValue) {

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/itemencryptor/model/OpaqueError.java

-34
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,8 @@ public class OpaqueError extends RuntimeException {
1010
*/
1111
private final Object obj;
1212

13-
/**
14-
* A best effort text representation of obj.
15-
*/
16-
private final String altText;
17-
1813
protected OpaqueError(BuilderImpl builder) {
1914
super(messageFromBuilder(builder), builder.cause());
20-
this.altText = builder.altText();
2115
this.obj = builder.obj();
2216
}
2317

@@ -52,13 +46,6 @@ public Object obj() {
5246
return this.obj;
5347
}
5448

55-
/**
56-
* @return A best effort text representation of obj.
57-
*/
58-
public String altText() {
59-
return this.altText;
60-
}
61-
6249
public Builder toBuilder() {
6350
return new BuilderImpl(this);
6451
}
@@ -98,16 +85,6 @@ public interface Builder {
9885
*/
9986
Object obj();
10087

101-
/**
102-
* @param altText A best effort text representation of obj.
103-
*/
104-
Builder altText(String altText);
105-
106-
/**
107-
* @return A best effort text representation of obj.
108-
*/
109-
String altText();
110-
11188
OpaqueError build();
11289
}
11390

@@ -119,8 +96,6 @@ static class BuilderImpl implements Builder {
11996

12097
protected Object obj;
12198

122-
protected String altText;
123-
12499
protected BuilderImpl() {}
125100

126101
protected BuilderImpl(OpaqueError model) {
@@ -156,15 +131,6 @@ public Object obj() {
156131
return this.obj;
157132
}
158133

159-
public Builder altText(String altText) {
160-
this.altText = altText;
161-
return this;
162-
}
163-
164-
public String altText() {
165-
return this.altText;
166-
}
167-
168134
public OpaqueError build() {
169135
if (
170136
this.obj != null && this.cause == null && this.obj instanceof Throwable

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/model/OpaqueError.java

-34
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,8 @@ public class OpaqueError extends RuntimeException {
1010
*/
1111
private final Object obj;
1212

13-
/**
14-
* A best effort text representation of obj.
15-
*/
16-
private final String altText;
17-
1813
protected OpaqueError(BuilderImpl builder) {
1914
super(messageFromBuilder(builder), builder.cause());
20-
this.altText = builder.altText();
2115
this.obj = builder.obj();
2216
}
2317

@@ -52,13 +46,6 @@ public Object obj() {
5246
return this.obj;
5347
}
5448

55-
/**
56-
* @return A best effort text representation of obj.
57-
*/
58-
public String altText() {
59-
return this.altText;
60-
}
61-
6249
public Builder toBuilder() {
6350
return new BuilderImpl(this);
6451
}
@@ -98,16 +85,6 @@ public interface Builder {
9885
*/
9986
Object obj();
10087

101-
/**
102-
* @param altText A best effort text representation of obj.
103-
*/
104-
Builder altText(String altText);
105-
106-
/**
107-
* @return A best effort text representation of obj.
108-
*/
109-
String altText();
110-
11188
OpaqueError build();
11289
}
11390

@@ -119,8 +96,6 @@ static class BuilderImpl implements Builder {
11996

12097
protected Object obj;
12198

122-
protected String altText;
123-
12499
protected BuilderImpl() {}
125100

126101
protected BuilderImpl(OpaqueError model) {
@@ -156,15 +131,6 @@ public Object obj() {
156131
return this.obj;
157132
}
158133

159-
public Builder altText(String altText) {
160-
this.altText = altText;
161-
return this;
162-
}
163-
164-
public String altText() {
165-
return this.altText;
166-
}
167-
168134
public OpaqueError build() {
169135
if (
170136
this.obj != null && this.cause == null && this.obj instanceof Throwable

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/transforms/ToDafny.java

+2-16
Original file line numberDiff line numberDiff line change
@@ -113,25 +113,11 @@ public static Error Error(RuntimeException nativeValue) {
113113
if (nativeValue instanceof CollectionOfErrors) {
114114
return ToDafny.Error((CollectionOfErrors) nativeValue);
115115
}
116-
return Error.create_Opaque(
117-
nativeValue,
118-
dafny.DafnySequence.asString(
119-
java.util.Objects.nonNull(nativeValue.getMessage())
120-
? nativeValue.getMessage()
121-
: ""
122-
)
123-
);
116+
return Error.create_Opaque(nativeValue);
124117
}
125118

126119
public static Error Error(OpaqueError nativeValue) {
127-
return Error.create_Opaque(
128-
nativeValue.obj(),
129-
dafny.DafnySequence.asString(
130-
java.util.Objects.nonNull(nativeValue.altText())
131-
? nativeValue.altText()
132-
: ""
133-
)
134-
);
120+
return Error.create_Opaque(nativeValue.obj());
135121
}
136122

137123
public static Error Error(CollectionOfErrors nativeValue) {

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/dynamodb/transforms/model/OpaqueError.java

-34
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,8 @@ public class OpaqueError extends RuntimeException {
1010
*/
1111
private final Object obj;
1212

13-
/**
14-
* A best effort text representation of obj.
15-
*/
16-
private final String altText;
17-
1813
protected OpaqueError(BuilderImpl builder) {
1914
super(messageFromBuilder(builder), builder.cause());
20-
this.altText = builder.altText();
2115
this.obj = builder.obj();
2216
}
2317

@@ -52,13 +46,6 @@ public Object obj() {
5246
return this.obj;
5347
}
5448

55-
/**
56-
* @return A best effort text representation of obj.
57-
*/
58-
public String altText() {
59-
return this.altText;
60-
}
61-
6249
public Builder toBuilder() {
6350
return new BuilderImpl(this);
6451
}
@@ -98,16 +85,6 @@ public interface Builder {
9885
*/
9986
Object obj();
10087

101-
/**
102-
* @param altText A best effort text representation of obj.
103-
*/
104-
Builder altText(String altText);
105-
106-
/**
107-
* @return A best effort text representation of obj.
108-
*/
109-
String altText();
110-
11188
OpaqueError build();
11289
}
11390

@@ -119,8 +96,6 @@ static class BuilderImpl implements Builder {
11996

12097
protected Object obj;
12198

122-
protected String altText;
123-
12499
protected BuilderImpl() {}
125100

126101
protected BuilderImpl(OpaqueError model) {
@@ -156,15 +131,6 @@ public Object obj() {
156131
return this.obj;
157132
}
158133

159-
public Builder altText(String altText) {
160-
this.altText = altText;
161-
return this;
162-
}
163-
164-
public String altText() {
165-
return this.altText;
166-
}
167-
168134
public OpaqueError build() {
169135
if (
170136
this.obj != null && this.cause == null && this.obj instanceof Throwable

DynamoDbEncryption/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/dbencryptionsdk/structuredencryption/ToDafny.java

+2-16
Original file line numberDiff line numberDiff line change
@@ -56,25 +56,11 @@ public static Error Error(RuntimeException nativeValue) {
5656
if (nativeValue instanceof CollectionOfErrors) {
5757
return ToDafny.Error((CollectionOfErrors) nativeValue);
5858
}
59-
return Error.create_Opaque(
60-
nativeValue,
61-
dafny.DafnySequence.asString(
62-
java.util.Objects.nonNull(nativeValue.getMessage())
63-
? nativeValue.getMessage()
64-
: ""
65-
)
66-
);
59+
return Error.create_Opaque(nativeValue);
6760
}
6861

6962
public static Error Error(OpaqueError nativeValue) {
70-
return Error.create_Opaque(
71-
nativeValue.obj(),
72-
dafny.DafnySequence.asString(
73-
java.util.Objects.nonNull(nativeValue.altText())
74-
? nativeValue.altText()
75-
: ""
76-
)
77-
);
63+
return Error.create_Opaque(nativeValue.obj());
7864
}
7965

8066
public static Error Error(CollectionOfErrors nativeValue) {

0 commit comments

Comments
 (0)