Aspose.Email for Java 23.5 Release Notes

All Changes

EMAILNET-40926Add Appoinment.Version propertyEnhancement
EMAILNET-40987VCardSaveOptions RequestEnhancement
EMAILNET-40709Add overloads for TgzReader Constructor and method GetTotalItemsCountEnhancement
EMAILNET-41030Problem with creating folder hierarchy in pstEnhancement
EMAILNET-41074not able to Load Attach fileBug
EMAILNET-41061High memory usage while sending/receiving messages usign smtp/imap clientBug
EMAILNET-41056Custom headers not fetched via GraphClientBug
EMAILNET-41054‘On behalf’ does not work correctlyBug
EMAILNET-41047Custom header not rendered in MHTBug
EMAILNET-41060MSG to MHTML: Incorrect styling and formattingBug
EMAILNET-41051Exception in Appointment from Mapi to IcsBug
EMAILNET-41046System.NullReferenceException raised when save vcf to msgBug
EMAILJAVA-35179Time of PST mail expired property change after adding PSTBug
EMAILJAVA-35176Email address is not valid when loading a task item (MapiTask.fromVTodo)Bug
EMAILJAVA-35175Not able to convert MapiMessage to MapiTaskBug

saving as msg

EMAILJAVA-35173MSG to MHTML: Table alignment is incorrectBug
EMAILJAVA-35172VCardContact nickname not written to vcfBug
EMAILJAVA-35171MSG to MHTML: Incorrect styling and formattingBug
EMAILJAVA-35166Color formatting, text alignment are not converted correctly and also some text is missing in email to PDF conversionBug

New Enhancements

Adding the Appointment.Version property

The Appointment class now includes a Version property, which enables users to retrieve the version of their ICS/VCS files. This property assists to determine which version their files are based on, ensuring integration with other systems and apps.

Code sample:

Appointment app = Appointment.load("meeting.ics");

if (app.getVersion() == "1.0")
    // do something

Adding the VCardSaveOptions

We added the new class to our API: VCardSaveOptions. This class enhances the capabilities of VCard contact management, allowing users to customize the saving behavior when working with vCard files.

VCardSaveOptions class has the following properties:

  • VCardVersion - enables users to specify the desired vCard version when saving contact items. By default, the class is set to use vCard version 2.1 (VCardVersion.V21).

  • UseExtensions - allows users to control whether extended fields can be used when saving vCard files. When set to true (default), extensions are permitted, providing compatibility with custom fields and additional contact information.

  • PreferredTextEncoding - the encoding to be used when saving vCard contact items.

Code sample:

VCardContact cont = VCardContact.load(fileName, StandardCharsets.UTF_8);
VCardSaveOptions opt = new VCardSaveOptions();
opt.setPreferredTextEncoding(StandardCharsets.UTF_8);"my.vcard", opt);

Adding GetTotalItemsCount method to TgzReader class

We have added the getTotalItemsCount() method to TgzReader class. It returns the total number of message items contained in the storage.

Code sample:

try (TgzReader reader = new TgzReader(fileName)) {
    int count = reader.getTotalItemsCount();

Retrieve a PST subfolder by path

The FolderInfo.getSubFolder(String name, boolean ignoreCase, boolean handlePathSeparator) method overload was added. It retrieves a subfolder with the specified name from the current PST folder.

It has the following parameters:

  • nameparameter specifies the name of the subfolder to retrieve.
  • ignoreCase parameter determines whether the search for the subfolder name should be case-sensitive or case-insensitive. If set to true, the search will be case-insensitive, otherwise, it will be case-sensitive.
  • handlePathSeparator parameter specifies whether the specified folder name should be treated as a path if it contains backslashes. If set to true, the method will interpret the folder name as a path, attempting to navigate to the subfolder using the path. If set to false, the method will treat the folder name as a simple name, searching for a subfolder with an exact name match.

Code sample:

FolderInfo folder = pst.getRootFolder().getSubFolder("Inbox\Reports\Jan", true, true);

In this sample, the method will return a ‘Jan’ named folder that is located at the Inbox\Reports\ path relative to the root folder.