Skip to content

Commit c233164

Browse files
Merge remote-tracking branch 'origin/master' into release
2 parents 4ed203a + e705847 commit c233164

17 files changed

+616
-5
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## [24.11.0] - Aspose Words Cloud for Dart 24.11 Release Notes
2+
3+
- Added GetAllRevisions method to obtain all available revisions in document.
4+
- Added AppendAllEntriesToOneSection parameter to AppendDocument method to append entries to the same section.
5+
6+
17
## [24.9.0] - Aspose Words Cloud for Dart 24.9 Release Notes
28

39
- Added digital signature methds for DOC, DOCX, XPS, or ODT documents.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Add this dependency to your *pubspec.yaml*:
2727

2828
```yaml
2929
dependencies:
30-
aspose_words_cloud: 24.10.0
30+
aspose_words_cloud: 24.11.0
3131
```
3232
3333
## Getting Started

lib/aspose_words_cloud.dart

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,10 @@ export 'src/models/replace_text_parameters.dart';
227227
export 'src/models/replace_text_response.dart';
228228
export 'src/models/report_build_options.dart';
229229
export 'src/models/report_engine_settings.dart';
230+
export 'src/models/revision_collection.dart';
231+
export 'src/models/revision.dart';
230232
export 'src/models/revisions_modification_response.dart';
233+
export 'src/models/revisions_response.dart';
231234
export 'src/models/rtf_save_options_data.dart';
232235
export 'src/models/run_base.dart';
233236
export 'src/models/run_insert.dart';
@@ -407,6 +410,8 @@ export 'src/requests/delete_watermark_request.dart';
407410
export 'src/requests/download_file_request.dart';
408411
export 'src/requests/execute_mail_merge_online_request.dart';
409412
export 'src/requests/execute_mail_merge_request.dart';
413+
export 'src/requests/get_all_revisions_online_request.dart';
414+
export 'src/requests/get_all_revisions_request.dart';
410415
export 'src/requests/get_available_fonts_request.dart';
411416
export 'src/requests/get_bookmark_by_name_online_request.dart';
412417
export 'src/requests/get_bookmark_by_name_request.dart';

lib/src/api_client.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@ class ApiClient {
518518
}
519519

520520
httpRequest.headers['x-aspose-client'] = 'dart sdk';
521-
httpRequest.headers['x-aspose-client-version'] = '24.10';
521+
httpRequest.headers['x-aspose-client-version'] = '24.11';
522522
httpRequest.headers['Authorization'] = await _getAuthToken();
523523
httpRequest.headers.addAll(requestData.headers);
524524

lib/src/models/document_entry_list.dart

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,13 @@ import '../../aspose_words_cloud.dart';
3131

3232
/// Represents a list of documents which will be appended to the original resource document.
3333
class DocumentEntryList extends BaseEntryList {
34+
/// Gets or sets a value indicating whether to append all documents to the same section.
35+
bool? _appendAllEntriesToOneSection;
36+
37+
bool? get appendAllEntriesToOneSection => _appendAllEntriesToOneSection;
38+
set appendAllEntriesToOneSection(bool? val) => _appendAllEntriesToOneSection = val;
39+
40+
3441
/// Gets or sets a value indicating whether to apply headers and footers from base document to appending documents. The default value is true.
3542
bool? _applyBaseDocumentHeadersAndFootersToAppendingDocuments;
3643

@@ -52,6 +59,12 @@ class DocumentEntryList extends BaseEntryList {
5259
}
5360

5461
super.deserialize(json);
62+
if (json.containsKey('AppendAllEntriesToOneSection')) {
63+
appendAllEntriesToOneSection = json['AppendAllEntriesToOneSection'] as bool;
64+
} else {
65+
appendAllEntriesToOneSection = null;
66+
}
67+
5568
if (json.containsKey('ApplyBaseDocumentHeadersAndFootersToAppendingDocuments')) {
5669
applyBaseDocumentHeadersAndFootersToAppendingDocuments = json['ApplyBaseDocumentHeadersAndFootersToAppendingDocuments'] as bool;
5770
} else {
@@ -73,6 +86,10 @@ class DocumentEntryList extends BaseEntryList {
7386
Map<String, dynamic> serialize() {
7487
var _result = <String, dynamic>{};
7588
_result.addAll(super.serialize());
89+
if (appendAllEntriesToOneSection != null) {
90+
_result['AppendAllEntriesToOneSection'] = appendAllEntriesToOneSection!;
91+
}
92+
7693
if (applyBaseDocumentHeadersAndFootersToAppendingDocuments != null) {
7794
_result['ApplyBaseDocumentHeadersAndFootersToAppendingDocuments'] = applyBaseDocumentHeadersAndFootersToAppendingDocuments!;
7895
}

lib/src/models/model_base.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,10 @@ abstract class ModelBase {
220220
'ReplaceTextResponse, _': () => ReplaceTextResponse(),
221221
'ReportBuildOptions, _': () => throw ApiException(400, 'Invalid type of class.'),
222222
'ReportEngineSettings, _': () => ReportEngineSettings(),
223+
'Revision, _': () => Revision(),
224+
'RevisionCollection, _': () => RevisionCollection(),
223225
'RevisionsModificationResponse, _': () => RevisionsModificationResponse(),
226+
'RevisionsResponse, _': () => RevisionsResponse(),
224227
'RtfSaveOptionsData, _': () => RtfSaveOptionsData(),
225228
'Run, _': () => Run(),
226229
'RunInsert, _': () => RunInsert(),

lib/src/models/revision.dart

Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,127 @@
1+
/*
2+
* --------------------------------------------------------------------------------
3+
* <copyright company="Aspose" file="revision.dart">
4+
* Copyright (c) 2024 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+
/// Revision Dto.
33+
class Revision implements ModelBase {
34+
/// Gets or sets the revision author.
35+
String? _revisionAuthor;
36+
37+
String? get revisionAuthor => _revisionAuthor;
38+
set revisionAuthor(String? val) => _revisionAuthor = val;
39+
40+
41+
/// Gets or sets the revision date time.
42+
DateTime? _revisionDateTime;
43+
44+
DateTime? get revisionDateTime => _revisionDateTime;
45+
set revisionDateTime(DateTime? val) => _revisionDateTime = val;
46+
47+
48+
/// Gets or sets the revision text.
49+
String? _revisionText;
50+
51+
String? get revisionText => _revisionText;
52+
set revisionText(String? val) => _revisionText = val;
53+
54+
55+
/// Gets or sets the revision type.
56+
String? _revisionType;
57+
58+
String? get revisionType => _revisionType;
59+
set revisionType(String? val) => _revisionType = val;
60+
61+
62+
@override
63+
void deserialize(Map<String, dynamic>? json) {
64+
if (json == null) {
65+
throw ApiException(400, 'Failed to deserialize Revision data model.');
66+
}
67+
68+
if (json.containsKey('RevisionAuthor')) {
69+
revisionAuthor = json['RevisionAuthor'] as String;
70+
} else {
71+
revisionAuthor = null;
72+
}
73+
74+
if (json.containsKey('RevisionDateTime')) {
75+
revisionDateTime = DateTime.parse(json['RevisionDateTime'] as String);
76+
} else {
77+
revisionDateTime = null;
78+
}
79+
80+
if (json.containsKey('RevisionText')) {
81+
revisionText = json['RevisionText'] as String;
82+
} else {
83+
revisionText = null;
84+
}
85+
86+
if (json.containsKey('RevisionType')) {
87+
revisionType = json['RevisionType'] as String;
88+
} else {
89+
revisionType = null;
90+
}
91+
}
92+
93+
@override
94+
Map<String, dynamic> serialize() {
95+
var _result = <String, dynamic>{};
96+
if (revisionAuthor != null) {
97+
_result['RevisionAuthor'] = revisionAuthor!;
98+
}
99+
100+
if (revisionDateTime != null) {
101+
_result['RevisionDateTime'] = revisionDateTime!.toIso8601String();
102+
}
103+
104+
if (revisionText != null) {
105+
_result['RevisionText'] = revisionText!;
106+
}
107+
108+
if (revisionType != null) {
109+
_result['RevisionType'] = revisionType!;
110+
}
111+
return _result;
112+
}
113+
114+
@override
115+
void getFilesContent(List<FileReference> resultFilesContent) {
116+
}
117+
118+
@override
119+
void validate() {
120+
if (revisionDateTime == null)
121+
{
122+
throw new ApiException(400, 'Property RevisionDateTime in Revision is required.');
123+
}
124+
}
125+
}
126+
127+
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
/*
2+
* --------------------------------------------------------------------------------
3+
* <copyright company="Aspose" file="revision_collection.dart">
4+
* Copyright (c) 2024 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+
/// RevisionCollection DTO.
33+
class RevisionCollection implements ModelBase {
34+
/// Gets or sets the revisions.
35+
List<Revision?>? _revisions;
36+
37+
List<Revision?>? get revisions => _revisions;
38+
set revisions(List<Revision?>? val) => _revisions = val;
39+
40+
41+
@override
42+
void deserialize(Map<String, dynamic>? json) {
43+
if (json == null) {
44+
throw ApiException(400, 'Failed to deserialize RevisionCollection data model.');
45+
}
46+
47+
if (json.containsKey('Revisions')) {
48+
// Array processing
49+
revisions = <Revision>[];
50+
for(final _element in json['Revisions']) {
51+
revisions!.add(ModelBase.createInstance< Revision >(_element as Map<String, dynamic>));
52+
}
53+
} else {
54+
revisions = null;
55+
}
56+
}
57+
58+
@override
59+
Map<String, dynamic> serialize() {
60+
var _result = <String, dynamic>{};
61+
if (revisions != null) {
62+
_result['Revisions'] = revisions!.map((_element) => _element?.serialize()).toList();
63+
}
64+
return _result;
65+
}
66+
67+
@override
68+
void getFilesContent(List<FileReference> resultFilesContent) {
69+
}
70+
71+
@override
72+
void validate() {
73+
74+
for (final elementRevisions in revisions ?? [])
75+
{
76+
elementRevisions?.validate();
77+
}
78+
79+
}
80+
}
81+
82+
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
/*
2+
* --------------------------------------------------------------------------------
3+
* <copyright company="Aspose" file="revisions_response.dart">
4+
* Copyright (c) 2024 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+
/// The revision response.
33+
class RevisionsResponse extends WordsResponse {
34+
/// Gets or sets Revisions.
35+
RevisionCollection? _revisions;
36+
37+
RevisionCollection? get revisions => _revisions;
38+
set revisions(RevisionCollection? val) => _revisions = val;
39+
40+
41+
@override
42+
void deserialize(Map<String, dynamic>? json) {
43+
if (json == null) {
44+
throw ApiException(400, 'Failed to deserialize RevisionsResponse data model.');
45+
}
46+
47+
super.deserialize(json);
48+
if (json.containsKey('RequestId')) {
49+
requestId = json['RequestId'] as String;
50+
} else {
51+
requestId = null;
52+
}
53+
54+
if (json.containsKey('Revisions')) {
55+
revisions = ModelBase.createInstance< RevisionCollection >(json['Revisions'] as Map<String, dynamic>);
56+
} else {
57+
revisions = null;
58+
}
59+
}
60+
61+
@override
62+
Map<String, dynamic> serialize() {
63+
var _result = <String, dynamic>{};
64+
_result.addAll(super.serialize());
65+
if (revisions != null) {
66+
_result['Revisions'] = revisions!.serialize();
67+
}
68+
return _result;
69+
}
70+
71+
@override
72+
void getFilesContent(List<FileReference> resultFilesContent) {
73+
}
74+
75+
@override
76+
void validate() {
77+
super.validate();
78+
79+
revisions?.validate();
80+
81+
}
82+
}
83+
84+

0 commit comments

Comments
 (0)