Provides options for rendering Outlook data files.
The OutlookOptions class encapsulates various settings and parameters that can be used to control the rendering of Outlook data files (such as PST or OST files) in the GroupDocs.Viewer component.
OutlookOptions options = new OutlookOptions();
options.setAddressFilter("@gmail.com");
options.setFolder("folderName");
final HtmlViewOptions htmlViewOptions = HtmlViewOptions.forEmbeddedResources();
htmlViewOptions.setOutlookOptions(options);
try (Viewer viewer = new Viewer("mail.pst")) {
viewer.view(htmlViewOptions);
// Use the viewer object for further operations
}
Sets the maximum number of messages or items that can be rendered from one folder.
OutlookOptions()
public OutlookOptions()
getFolder()
public final String getFolder()
Gets the name of the folder to render. The name of the folder (e.g., Inbox, Sent Item, or Deleted Items) to render.
When rendering an Outlook data file, GroupDocs.Viewer renders messages from all folders contained in the file (including nested folders). Use this property to render items from a specific folder. For code example, see this documentation.
Returns:
java.lang.String - the name of the folder to render.
setFolder(String value)
public final void setFolder(String value)
Sets the name of the folder to render. The name of the folder (e.g., Inbox, Sent Item, or Deleted Items) to render.
When rendering an Outlook data file, GroupDocs.Viewer renders messages from all folders contained in the file (including nested folders). Use this property to render items from a specific folder. For code example, see this documentation.
Parameters:
Parameter
Type
Description
value
java.lang.String
The name of the folder to render.
getTextFilter()
public final String getTextFilter()
Gets the keywords used to filter messages.
Use this property to render all messages that contain specific text in the subject or body. For code example, see the documentation.
Returns:
java.lang.String - the keywords.
setTextFilter(String value)
public final void setTextFilter(String value)
Gets the keywords used to filter messages.
Use this property to render all messages that contain specific text in the subject or body. For code example, see the documentation.
Parameters:
Parameter
Type
Description
value
java.lang.String
The keywords.
getAddressFilter()
public final String getAddressFilter()
Gets the email address used to filter messages by sender or recipient.
Use this property to render all messages that contain specific text in the sender\ufffds or recipient\ufffds address. For code example, see the documentation.
Returns:
java.lang.String - the email address used to filter messages.
setAddressFilter(String value)
public final void setAddressFilter(String value)
Sets the email address used to filter messages by sender or recipient.
Use this property to render all messages that contain specific text in the sender\ufffds or recipient\ufffds address. For code example, see the documentation.
Parameters:
Parameter
Type
Description
value
java.lang.String
The email address used to filter messages.
getMaxItemsInFolder()
public final int getMaxItemsInFolder()
Gets the maximum number of messages or items that can be rendered from one folder.
Outlook data files can be large and retrieving all messages can take significant time. This setting limits the maximum number of messages or items (such as contacts and tasks) that are rendered. The default value is 50. Set the value to 0 to render all messages. For code example, see the documentation.
Returns:
int - the maximum number of messages or items that can be rendered from one folder.
setMaxItemsInFolder(int value)
public final void setMaxItemsInFolder(int value)
Sets the maximum number of messages or items that can be rendered from one folder.
Outlook data files can be large and retrieving all messages can take significant time. This setting limits the maximum number of messages or items (such as contacts and tasks) that are rendered. The default value is 50. Set the value to 0 to render all messages. For code example, see the documentation.
Parameters:
Parameter
Type
Description
value
int
The maximum number of messages or items that can be rendered from one folder.
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.