Skip to content

Commit 6d46534

Browse files
SDK regenerated by CI server [ci skip]
1 parent b4c1f2a commit 6d46534

File tree

3 files changed

+87
-2
lines changed

3 files changed

+87
-2
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ This repository contains Aspose.Words Cloud SDK for Swift source code. This SDK
1313
* Watermarks and protection
1414
* Full read & write access to Document Object Model, including sections, paragraphs, text, images, tables, headers/footers and many others
1515

16+
## Enhancements in Version 25.4
17+
18+
- Added 'AttachmentsEmbeddingMode' property for PdfSaveOptionsData class.
19+
- Added 'UpdateAmbiguousTextFont' property for SaveOptionsData class.
20+
21+
1622
## Enhancements in Version 25.2
1723

1824
- Added 'IdPrefix' property for HtmlFixedSaveOptionsData and SvgSaveOptionsData class.

Sources/AsposeWordsCloud/Model/PdfSaveOptionsData.swift

Lines changed: 51 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,22 @@ import Foundation
2929

3030
// Container class for pdf save options.
3131
public class PdfSaveOptionsData : FixedPageSaveOptionsData {
32+
// Gets or sets a value determining how attachments are embedded to the PDF document.
33+
// Default value is None and attachments are not embedded.
34+
// PDF/A-1, PDF/A-2 and regular PDF/A-4 (not PDF/A-4f) standards do not allow embedded files.
35+
// None value will be used automatically.
36+
public enum AttachmentsEmbeddingMode : String, Codable
37+
{
38+
// Enum value "_none"
39+
case _none = "None"
40+
41+
// Enum value "annotations"
42+
case annotations = "Annotations"
43+
44+
// Enum value "documentEmbeddedFiles"
45+
case documentEmbeddedFiles = "DocumentEmbeddedFiles"
46+
}
47+
3248
// Gets or sets the PDF standards compliance level for output documents.
3349
public enum Compliance : String, Codable
3450
{
@@ -178,6 +194,18 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
178194
case fitBox = "FitBox"
179195
}
180196

197+
// Field of attachmentsEmbeddingMode. Container class for pdf save options.
198+
private var _attachmentsEmbeddingMode : AttachmentsEmbeddingMode? = nil;
199+
200+
public var attachmentsEmbeddingMode : AttachmentsEmbeddingMode? {
201+
get {
202+
return self._attachmentsEmbeddingMode;
203+
}
204+
set {
205+
self._attachmentsEmbeddingMode = newValue;
206+
}
207+
}
208+
181209
// Field of cacheBackgroundGraphics. Container class for pdf save options.
182210
private var _cacheBackgroundGraphics : Bool? = nil;
183211

@@ -536,6 +564,7 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
536564
}
537565

538566
private enum CodingKeys: String, CodingKey {
567+
case attachmentsEmbeddingMode = "AttachmentsEmbeddingMode";
539568
case cacheBackgroundGraphics = "CacheBackgroundGraphics";
540569
case compliance = "Compliance";
541570
case createNoteHyperlinks = "CreateNoteHyperlinks";
@@ -574,6 +603,10 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
574603

575604
public required init(from json: [String: Any]) throws {
576605
try super.init(from: json);
606+
if let raw_attachmentsEmbeddingMode = json["AttachmentsEmbeddingMode"] as? String {
607+
self.attachmentsEmbeddingMode = AttachmentsEmbeddingMode(rawValue: raw_attachmentsEmbeddingMode);
608+
}
609+
577610
self.cacheBackgroundGraphics = json["CacheBackgroundGraphics"] as? Bool;
578611
if let raw_compliance = json["Compliance"] as? String {
579612
self.compliance = Compliance(rawValue: raw_compliance);
@@ -644,6 +677,7 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
644677
public required init(from decoder: Decoder) throws {
645678
try super.init(from: decoder);
646679
let container = try decoder.container(keyedBy: CodingKeys.self);
680+
self.attachmentsEmbeddingMode = try container.decodeIfPresent(AttachmentsEmbeddingMode.self, forKey: .attachmentsEmbeddingMode);
647681
self.cacheBackgroundGraphics = try container.decodeIfPresent(Bool.self, forKey: .cacheBackgroundGraphics);
648682
self.compliance = try container.decodeIfPresent(Compliance.self, forKey: .compliance);
649683
self.createNoteHyperlinks = try container.decodeIfPresent(Bool.self, forKey: .createNoteHyperlinks);
@@ -678,6 +712,9 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
678712
public override func encode(to encoder: Encoder) throws {
679713
try super.encode(to: encoder);
680714
var container = encoder.container(keyedBy: CodingKeys.self);
715+
if (self.attachmentsEmbeddingMode != nil) {
716+
try container.encode(self.attachmentsEmbeddingMode, forKey: .attachmentsEmbeddingMode);
717+
}
681718
if (self.cacheBackgroundGraphics != nil) {
682719
try container.encode(self.cacheBackgroundGraphics, forKey: .cacheBackgroundGraphics);
683720
}
@@ -779,6 +816,18 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
779816

780817
}
781818

819+
// Sets attachmentsEmbeddingMode. Gets or sets a value determining how attachments are embedded to the PDF document. Default value is None and attachments are not embedded. PDF/A-1, PDF/A-2 and regular PDF/A-4 (not PDF/A-4f) standards do not allow embedded files. None value will be used automatically.
820+
public func setAttachmentsEmbeddingMode(attachmentsEmbeddingMode : AttachmentsEmbeddingMode?) -> PdfSaveOptionsData {
821+
self.attachmentsEmbeddingMode = attachmentsEmbeddingMode;
822+
return self;
823+
}
824+
825+
// Gets attachmentsEmbeddingMode. Gets or sets a value determining how attachments are embedded to the PDF document. Default value is None and attachments are not embedded. PDF/A-1, PDF/A-2 and regular PDF/A-4 (not PDF/A-4f) standards do not allow embedded files. None value will be used automatically.
826+
public func getAttachmentsEmbeddingMode() -> AttachmentsEmbeddingMode? {
827+
return self.attachmentsEmbeddingMode;
828+
}
829+
830+
782831
// Sets cacheBackgroundGraphics. Gets or sets a value determining whether or not to cache graphics placed in document's background. Default value is true and background graphics are written to the PDF document as an xObject. When the value is false background graphics are not cached. Some shapes are not supported for caching(shapes with fields, bookmarks, HRefs). Document background graphic is various shapes, charts, images placed in the footer or header, well as background and border of a page.
783832
public func setCacheBackgroundGraphics(cacheBackgroundGraphics : Bool?) -> PdfSaveOptionsData {
784833
self.cacheBackgroundGraphics = cacheBackgroundGraphics;
@@ -864,14 +913,14 @@ public class PdfSaveOptionsData : FixedPageSaveOptionsData {
864913

865914

866915
// Sets embedAttachments. Gets or sets a value determining whether or not to embed attachments to the PDF document. Default value is false and attachments are not embedded. When the value is true attachments are embedded to the PDF document. Embedding attachments is not supported when saving to PDF/A and PDF/UA compliance. false value will be used automatically. Embedding attachments is not supported when encryption is enabled. false value will be used automatically.
867-
@available(*, deprecated, message: "This property will be removed in the future.")
916+
@available(*, deprecated, message: "Obsolete, please use AttachmentsEmbeddingMode instead.")
868917
public func setEmbedAttachments(embedAttachments : Bool?) -> PdfSaveOptionsData {
869918
self.embedAttachments = embedAttachments;
870919
return self;
871920
}
872921

873922
// Gets embedAttachments. Gets or sets a value determining whether or not to embed attachments to the PDF document. Default value is false and attachments are not embedded. When the value is true attachments are embedded to the PDF document. Embedding attachments is not supported when saving to PDF/A and PDF/UA compliance. false value will be used automatically. Embedding attachments is not supported when encryption is enabled. false value will be used automatically.
874-
@available(*, deprecated, message: "This property will be removed in the future.")
923+
@available(*, deprecated, message: "Obsolete, please use AttachmentsEmbeddingMode instead.")
875924
public func getEmbedAttachments() -> Bool? {
876925
return self.embedAttachments;
877926
}

Sources/AsposeWordsCloud/Model/SaveOptionsData.swift

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,18 @@ public class SaveOptionsData : Codable, WordsApiModel {
163163
}
164164
}
165165

166+
// Field of updateAmbiguousTextFont. base container class for save options data.
167+
private var _updateAmbiguousTextFont : Bool? = nil;
168+
169+
public var updateAmbiguousTextFont : Bool? {
170+
get {
171+
return self._updateAmbiguousTextFont;
172+
}
173+
set {
174+
self._updateAmbiguousTextFont = newValue;
175+
}
176+
}
177+
166178
// Field of updateCreatedTimeProperty. base container class for save options data.
167179
private var _updateCreatedTimeProperty : Bool? = nil;
168180

@@ -240,6 +252,7 @@ public class SaveOptionsData : Codable, WordsApiModel {
240252
case dmlRenderingMode = "DmlRenderingMode";
241253
case fileName = "FileName";
242254
case imlRenderingMode = "ImlRenderingMode";
255+
case updateAmbiguousTextFont = "UpdateAmbiguousTextFont";
243256
case updateCreatedTimeProperty = "UpdateCreatedTimeProperty";
244257
case updateFields = "UpdateFields";
245258
case updateLastPrintedProperty = "UpdateLastPrintedProperty";
@@ -275,6 +288,7 @@ public class SaveOptionsData : Codable, WordsApiModel {
275288
self.imlRenderingMode = ImlRenderingMode(rawValue: raw_imlRenderingMode);
276289
}
277290

291+
self.updateAmbiguousTextFont = json["UpdateAmbiguousTextFont"] as? Bool;
278292
self.updateCreatedTimeProperty = json["UpdateCreatedTimeProperty"] as? Bool;
279293
self.updateFields = json["UpdateFields"] as? Bool;
280294
self.updateLastPrintedProperty = json["UpdateLastPrintedProperty"] as? Bool;
@@ -292,6 +306,7 @@ public class SaveOptionsData : Codable, WordsApiModel {
292306
self.dmlRenderingMode = try container.decodeIfPresent(DmlRenderingMode.self, forKey: .dmlRenderingMode);
293307
self.fileName = try container.decodeIfPresent(String.self, forKey: .fileName);
294308
self.imlRenderingMode = try container.decodeIfPresent(ImlRenderingMode.self, forKey: .imlRenderingMode);
309+
self.updateAmbiguousTextFont = try container.decodeIfPresent(Bool.self, forKey: .updateAmbiguousTextFont);
295310
self.updateCreatedTimeProperty = try container.decodeIfPresent(Bool.self, forKey: .updateCreatedTimeProperty);
296311
self.updateFields = try container.decodeIfPresent(Bool.self, forKey: .updateFields);
297312
self.updateLastPrintedProperty = try container.decodeIfPresent(Bool.self, forKey: .updateLastPrintedProperty);
@@ -323,6 +338,9 @@ public class SaveOptionsData : Codable, WordsApiModel {
323338
if (self.imlRenderingMode != nil) {
324339
try container.encode(self.imlRenderingMode, forKey: .imlRenderingMode);
325340
}
341+
if (self.updateAmbiguousTextFont != nil) {
342+
try container.encode(self.updateAmbiguousTextFont, forKey: .updateAmbiguousTextFont);
343+
}
326344
if (self.updateCreatedTimeProperty != nil) {
327345
try container.encode(self.updateCreatedTimeProperty, forKey: .updateCreatedTimeProperty);
328346
}
@@ -439,6 +457,18 @@ public class SaveOptionsData : Codable, WordsApiModel {
439457
}
440458

441459

460+
// Sets updateAmbiguousTextFont. Gets or sets a value indicating whether the font attributes will be changed according to the character code being used.
461+
public func setUpdateAmbiguousTextFont(updateAmbiguousTextFont : Bool?) -> SaveOptionsData {
462+
self.updateAmbiguousTextFont = updateAmbiguousTextFont;
463+
return self;
464+
}
465+
466+
// Gets updateAmbiguousTextFont. Gets or sets a value indicating whether the font attributes will be changed according to the character code being used.
467+
public func getUpdateAmbiguousTextFont() -> Bool? {
468+
return self.updateAmbiguousTextFont;
469+
}
470+
471+
442472
// Sets updateCreatedTimeProperty. Gets or sets a value determining whether the Aspose.Words.Properties.BuiltInDocumentProperties.CreatedTime property is updated before saving. Default value is false.
443473
public func setUpdateCreatedTimeProperty(updateCreatedTimeProperty : Bool?) -> SaveOptionsData {
444474
self.updateCreatedTimeProperty = updateCreatedTimeProperty;

0 commit comments

Comments
 (0)