Skip to content

Commit 6f8d0e4

Browse files
SDK regenerated by CI server [ci skip]
1 parent 5a17cb0 commit 6f8d0e4

File tree

1 file changed

+5
-26
lines changed

1 file changed

+5
-26
lines changed

lib/src/models/signature.dart

Lines changed: 5 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ class Signature implements ModelBase {
5454

5555

5656
/// Gets or sets the type of the digital signature.
57-
Signature_SignatureTypeEnum? _signatureType;
57+
String? _signatureType;
5858

59-
Signature_SignatureTypeEnum? get signatureType => _signatureType;
60-
set signatureType(Signature_SignatureTypeEnum? val) => _signatureType = val;
59+
String? get signatureType => _signatureType;
60+
set signatureType(String? val) => _signatureType = val;
6161

6262

6363
/// Gets or sets an array of bytes representing a signature value as base64 string.
@@ -106,12 +106,7 @@ class Signature implements ModelBase {
106106
}
107107

108108
if (json.containsKey('SignatureType')) {
109-
switch (json['SignatureType'] as String) {
110-
case 'Unknown': signatureType = Signature_SignatureTypeEnum.unknown; break;
111-
case 'CryptoApi': signatureType = Signature_SignatureTypeEnum.cryptoApi; break;
112-
case 'XmlDsig': signatureType = Signature_SignatureTypeEnum.xmlDsig; break;
113-
default: signatureType = null; break;
114-
}
109+
signatureType = json['SignatureType'] as String;
115110
} else {
116111
signatureType = null;
117112
}
@@ -151,12 +146,7 @@ class Signature implements ModelBase {
151146
}
152147

153148
if (signatureType != null) {
154-
switch (signatureType!) {
155-
case Signature_SignatureTypeEnum.unknown: _result['SignatureType'] = 'Unknown'; break;
156-
case Signature_SignatureTypeEnum.cryptoApi: _result['SignatureType'] = 'CryptoApi'; break;
157-
case Signature_SignatureTypeEnum.xmlDsig: _result['SignatureType'] = 'XmlDsig'; break;
158-
default: break;
159-
}
149+
_result['SignatureType'] = signatureType!;
160150
}
161151

162152
if (signatureValue != null) {
@@ -183,22 +173,11 @@ class Signature implements ModelBase {
183173
{
184174
throw new ApiException(400, 'Property IsValid in Signature is required.');
185175
}
186-
if (signatureType == null)
187-
{
188-
throw new ApiException(400, 'Property SignatureType in Signature is required.');
189-
}
190176
if (signTime == null)
191177
{
192178
throw new ApiException(400, 'Property SignTime in Signature is required.');
193179
}
194180
}
195181
}
196182

197-
/// Gets or sets the type of the digital signature.
198-
enum Signature_SignatureTypeEnum
199-
{
200-
unknown,
201-
cryptoApi,
202-
xmlDsig
203-
}
204183

0 commit comments

Comments
 (0)