Skip to content

Commit 7438d25

Browse files
SDK regenerated by CI server [ci skip]
1 parent 69eb30d commit 7438d25

File tree

5 files changed

+204
-0
lines changed

5 files changed

+204
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
- Removed 'GraphicsQualityOptions' image save option as it no longer supported.
44
- Added query parameter 'displayIntermediateResults' for batch requests. If 'false', the last response in batch will be returned only. Default is 'true'
5+
- Added 'JsonDataLoadOptions' and 'XmlDataLoadOptions' to 'ReportEngineSettings'
56

67

78
## [21.8.0] - Aspose Words Cloud for Dart 21.8 Release Notes

lib/aspose_words_cloud.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,7 @@ export 'src/models/hyperlinks.dart';
135135
export 'src/models/hyperlinks_response.dart';
136136
export 'src/models/image_save_options_data.dart';
137137
export 'src/models/jpeg_save_options_data.dart';
138+
export 'src/models/json_data_load_options.dart';
138139
export 'src/models/link.dart';
139140
export 'src/models/link_element.dart';
140141
export 'src/models/list_format.dart';
@@ -274,6 +275,7 @@ export 'src/models/words_response.dart';
274275
export 'src/models/xaml_fixed_save_options_data.dart';
275276
export 'src/models/xaml_flow_save_options_data.dart';
276277
export 'src/models/xml_color.dart';
278+
export 'src/models/xml_data_load_options.dart';
277279
export 'src/models/xps_save_options_data.dart';
278280
export 'src/requests/accept_all_revisions_online_request.dart';
279281
export 'src/requests/accept_all_revisions_request.dart';
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
/*
2+
* --------------------------------------------------------------------------------
3+
* <copyright company="Aspose" file="json_data_load_options.dart">
4+
* Copyright (c) 2021 Aspose.Words for Cloud
5+
* </copyright>
6+
* <summary>
7+
* Permission is hereby granted, free of charge, to any person obtaining a copy
8+
* of this software and associated documentation files (the "Software"), to deal
9+
* in the Software without restriction, including without limitation the rights
10+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+
* copies of the Software, and to permit persons to whom the Software is
12+
* furnished to do so, subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included in all
15+
* copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23+
* SOFTWARE.
24+
* </summary>
25+
* --------------------------------------------------------------------------------
26+
*/
27+
28+
library aspose_words_cloud;
29+
30+
import '../../aspose_words_cloud.dart';
31+
32+
/// Represents options for parsing JSON data.
33+
class JsonDataLoadOptions implements ModelBase {
34+
/// Gets or sets a value indicating whether a generated data source will always contain
35+
/// an object for a JSON root element. If a JSON root element contains a single complex
36+
/// property, such an object is not created by default.
37+
bool alwaysGenerateRootObject;
38+
39+
/// Gets or sets exact formats for parsing JSON date-time values while loading JSON.
40+
/// The default is null.
41+
List<String> exactDateTimeParseFormats;
42+
43+
/// Gets or sets a mode for parsing JSON simple values (null, boolean, number, integer,
44+
/// and string) while loading JSON. Such a mode does not affect parsing of date-time
45+
/// values. The default is Aspose.Words.Reporting.JsonSimpleValueParseMode.Loose.
46+
JsonDataLoadOptions_SimpleValueParseModeEnum simpleValueParseMode;
47+
48+
@override
49+
void deserialize(Map<String, dynamic> json) {
50+
if (json == null) {
51+
throw ApiException(400, 'Failed to deserialize JsonDataLoadOptions data model.');
52+
}
53+
54+
if (json.containsKey('AlwaysGenerateRootObject')) {
55+
alwaysGenerateRootObject = json['AlwaysGenerateRootObject'] as bool;
56+
} else {
57+
alwaysGenerateRootObject = null;
58+
}
59+
60+
if (json.containsKey('ExactDateTimeParseFormats')) {
61+
// Array processing
62+
exactDateTimeParseFormats = <String>[];
63+
for(final _element in json['ExactDateTimeParseFormats']) {
64+
exactDateTimeParseFormats.add(_element as String);
65+
}
66+
} else {
67+
exactDateTimeParseFormats = null;
68+
}
69+
70+
if (json.containsKey('SimpleValueParseMode')) {
71+
switch (json['SimpleValueParseMode'] as String) {
72+
case 'Loose': simpleValueParseMode = JsonDataLoadOptions_SimpleValueParseModeEnum.loose; break;
73+
case 'Strict': simpleValueParseMode = JsonDataLoadOptions_SimpleValueParseModeEnum.strict; break;
74+
default: simpleValueParseMode = null; break;
75+
}
76+
} else {
77+
simpleValueParseMode = null;
78+
}
79+
}
80+
81+
@override
82+
Map<String, dynamic> serialize() {
83+
var _result = <String, dynamic>{};
84+
if (alwaysGenerateRootObject != null) {
85+
_result['AlwaysGenerateRootObject'] = alwaysGenerateRootObject;
86+
}
87+
88+
if (exactDateTimeParseFormats != null) {
89+
_result['ExactDateTimeParseFormats'] = exactDateTimeParseFormats;
90+
}
91+
92+
if (simpleValueParseMode != null) {
93+
switch (simpleValueParseMode) {
94+
case JsonDataLoadOptions_SimpleValueParseModeEnum.loose: _result['SimpleValueParseMode'] = 'Loose'; break;
95+
case JsonDataLoadOptions_SimpleValueParseModeEnum.strict: _result['SimpleValueParseMode'] = 'Strict'; break;
96+
default: break;
97+
}
98+
}
99+
return _result;
100+
}
101+
}
102+
103+
/// Gets or sets a mode for parsing JSON simple values (null, boolean, number, integer,
104+
/// and string) while loading JSON. Such a mode does not affect parsing of date-time
105+
/// values. The default is Aspose.Words.Reporting.JsonSimpleValueParseMode.Loose.
106+
enum JsonDataLoadOptions_SimpleValueParseModeEnum
107+
{
108+
loose,
109+
strict
110+
}
111+

lib/src/models/report_engine_settings.dart

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,15 @@ class ReportEngineSettings implements ModelBase {
4040
/// Gets or sets type of datasource.
4141
ReportEngineSettings_DataSourceTypeEnum dataSourceType;
4242

43+
/// Gets or sets the options for parsing JSON data.
44+
JsonDataLoadOptions jsonDataLoadOptions;
45+
4346
/// Gets or sets type of options to build report.
4447
List<ReportBuildOptionsEnum> reportBuildOptions;
4548

49+
/// Gets or sets the options for parsing XML data.
50+
XmlDataLoadOptions xmlDataLoadOptions;
51+
4652
@override
4753
void deserialize(Map<String, dynamic> json) {
4854
if (json == null) {
@@ -73,6 +79,13 @@ class ReportEngineSettings implements ModelBase {
7379
dataSourceType = null;
7480
}
7581

82+
if (json.containsKey('JsonDataLoadOptions')) {
83+
jsonDataLoadOptions = JsonDataLoadOptions();
84+
jsonDataLoadOptions.deserialize(json['JsonDataLoadOptions'] as Map<String, dynamic>);
85+
} else {
86+
jsonDataLoadOptions = null;
87+
}
88+
7689
if (json.containsKey('ReportBuildOptions')) {
7790
// Array processing
7891
reportBuildOptions = <ReportBuildOptionsEnum>[];
@@ -88,6 +101,13 @@ class ReportEngineSettings implements ModelBase {
88101
} else {
89102
reportBuildOptions = null;
90103
}
104+
105+
if (json.containsKey('XmlDataLoadOptions')) {
106+
xmlDataLoadOptions = XmlDataLoadOptions();
107+
xmlDataLoadOptions.deserialize(json['XmlDataLoadOptions'] as Map<String, dynamic>);
108+
} else {
109+
xmlDataLoadOptions = null;
110+
}
91111
}
92112

93113
@override
@@ -110,6 +130,10 @@ class ReportEngineSettings implements ModelBase {
110130
}
111131
}
112132

133+
if (jsonDataLoadOptions != null) {
134+
_result['JsonDataLoadOptions'] = jsonDataLoadOptions.serialize();
135+
}
136+
113137
if (reportBuildOptions != null) {
114138
_result['ReportBuildOptions'] = reportBuildOptions.map((_element) {
115139
switch (_element) {
@@ -121,6 +145,10 @@ class ReportEngineSettings implements ModelBase {
121145
}
122146
}).toList();
123147
}
148+
149+
if (xmlDataLoadOptions != null) {
150+
_result['XmlDataLoadOptions'] = xmlDataLoadOptions.serialize();
151+
}
124152
return _result;
125153
}
126154
}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
/*
2+
* --------------------------------------------------------------------------------
3+
* <copyright company="Aspose" file="xml_data_load_options.dart">
4+
* Copyright (c) 2021 Aspose.Words for Cloud
5+
* </copyright>
6+
* <summary>
7+
* Permission is hereby granted, free of charge, to any person obtaining a copy
8+
* of this software and associated documentation files (the "Software"), to deal
9+
* in the Software without restriction, including without limitation the rights
10+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+
* copies of the Software, and to permit persons to whom the Software is
12+
* furnished to do so, subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included in all
15+
* copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23+
* SOFTWARE.
24+
* </summary>
25+
* --------------------------------------------------------------------------------
26+
*/
27+
28+
library aspose_words_cloud;
29+
30+
import '../../aspose_words_cloud.dart';
31+
32+
/// Represents options for XML data loading.
33+
class XmlDataLoadOptions implements ModelBase {
34+
/// Gets or sets a flag indicating whether a generated data source will always contain an object for an XML root
35+
/// element. If an XML root element has no attributes and all its child elements have same names, such an object
36+
/// is not created by default.
37+
bool alwaysGenerateRootObject;
38+
39+
@override
40+
void deserialize(Map<String, dynamic> json) {
41+
if (json == null) {
42+
throw ApiException(400, 'Failed to deserialize XmlDataLoadOptions data model.');
43+
}
44+
45+
if (json.containsKey('AlwaysGenerateRootObject')) {
46+
alwaysGenerateRootObject = json['AlwaysGenerateRootObject'] as bool;
47+
} else {
48+
alwaysGenerateRootObject = null;
49+
}
50+
}
51+
52+
@override
53+
Map<String, dynamic> serialize() {
54+
var _result = <String, dynamic>{};
55+
if (alwaysGenerateRootObject != null) {
56+
_result['AlwaysGenerateRootObject'] = alwaysGenerateRootObject;
57+
}
58+
return _result;
59+
}
60+
}
61+
62+

0 commit comments

Comments
 (0)