|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.aspose.email.FolderInfo
public final class FolderInfo
Represents information about personal folder in PST.
Constructor Summary | |
---|---|
FolderInfo()
Initializes a new instance of the FolderInfo class. |
Method Summary | |
---|---|
String |
addMapiMessageItem(IMapiMessageItem item)
Adds the IMapiMessageItem object into folder. |
String |
addMessage(MapiMessage message)
Adds a new message into folder. |
FolderInfo |
addSubFolder(String name)
Adds the new subfolder. |
FolderInfo |
addSubFolder(String name,
String containerClass)
Adds the new subfolder. |
void |
changeDisplayName(String newName)
Changes the display name. |
void |
deleteChildItem(byte[] entryId)
Deletes the item (folder or message) by it's entryId. |
Iterable<FolderInfo> |
enumerateFolders()
Exposes the enumerator, which supports an iteration of subfolders in folder. |
Iterable<MapiMessage> |
enumerateMapiMessages()
Exposes the enumerator, which supports an iteration of messages in folder. |
Iterable<MessageObject> |
enumerateMessageObjects()
Exposes the enumerator, which supports an iteration of messages in folder. |
Iterable<MessageInfo> |
enumerateMessages()
Exposes the enumerator, which supports an iteration of messages in folder. |
Iterable<String> |
enumerateMessagesEntryId()
Enumerates the entryID of messages. |
String |
getContainerClass()
Gets container class of the folder object. |
int |
getContentCount()
Gets the total number of items in the folder. |
MessageInfoCollection |
getContents()
Get collection of messages. |
MessageInfoCollection |
getContents(boolean tryToReadCorruptedContents)
Get collection of messages. |
MessageInfoCollection |
getContents(int startIndex,
int count)
Gets the collection of messages. |
int |
getContentUnreadCount()
Gets the number of unread items in the folder. |
String |
getDisplayName()
Gets the display name of folder. |
byte[] |
getEntryId()
Gets the entry ID. |
String |
getEntryIdString()
Gets string representation of entry ID. |
Date |
getLastModificationTime()
|
MapiPropertyCollection |
getProperties()
Gets the folder properties. |
FolderInfo |
getSubFolder(String name)
Get subfolder. |
FolderInfoCollection |
getSubFolders()
Gets collection of subfolders. |
boolean |
hasSubFolders()
Gets a value indicating whether the Folder object has any subfolders. |
String |
retrieveFullPath()
Retrieves the full path of folder within the PST file. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FolderInfo()
Initializes a new instance of the FolderInfo
class.
Method Detail |
---|
public String getDisplayName()
Gets the display name of folder.
Value: The display name.
public int getContentCount()
Gets the total number of items in the folder.
Value: The content count.
public int getContentUnreadCount()
Gets the number of unread items in the folder.
Value: The content unread count.
public boolean hasSubFolders()
Gets a value indicating whether the Folder object has any subfolders.
Value: The has sub folders.
public String getContainerClass()
Gets container class of the folder object.
Value: The container class.
public Date getLastModificationTime()
public byte[] getEntryId()
Gets the entry ID.
Value: The entry id.
public String getEntryIdString()
Gets string representation of entry ID.
Value: The entry id string.
public MapiPropertyCollection getProperties()
Gets the folder properties.
public FolderInfoCollection getSubFolders()
Gets collection of subfolders.
public FolderInfo getSubFolder(String name)
Get subfolder.
name
- Name of subfolder.
public String retrieveFullPath()
Retrieves the full path of folder within the PST file.
public MessageInfoCollection getContents()
Get collection of messages.
public MessageInfoCollection getContents(int startIndex, int count)
Gets the collection of messages.
startIndex
- The start message index.count
- The number of messages that will be retrieved.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if startIndex less than 0.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if startIndex more or equal to total message count that folder contains.public Iterable<FolderInfo> enumerateFolders()
Exposes the enumerator, which supports an iteration of subfolders in folder.
System.Collections.Generic.IEnumerableltTgt
,
that represents an enumerator that iterates through a subfolders in folder.public Iterable<MessageInfo> enumerateMessages()
Exposes the enumerator, which supports an iteration of messages in folder.
System.Collections.Generic.IEnumerableltTgt
,
that represents an enumerator that iterates through a messages in folder.public Iterable<MessageObject> enumerateMessageObjects()
Exposes the enumerator, which supports an iteration of messages in folder.
System.Collections.Generic.IEnumerableltTgt
,
that represents an enumerator that iterates through a messages in folder.public Iterable<MapiMessage> enumerateMapiMessages()
Exposes the enumerator, which supports an iteration of messages in folder.
System.Collections.Generic.IEnumerableltTgt
,
that represents an enumerator that iterates through a messages in folder.public Iterable<String> enumerateMessagesEntryId()
Enumerates the entryID of messages.
public MessageInfoCollection getContents(boolean tryToReadCorruptedContents)
Get collection of messages.
tryToReadCorruptedContents
- If the value of this parameter is true,
the method will try to read the content even if the file is corrupted.
This value can be used if the GetContents() method throws an exception about the file corruption.
If the value of this parameter is false,
the method works in the same way as GetContents() method without parameters.
public FolderInfo addSubFolder(String name)
Adds the new subfolder.
name
- The name of subfolder.
com.aspose.email.ms.System.NotImplementedException
- throws, if a PST file version is ANSI.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if a subfolder name is null or empty.
IllegalStateException
- throws, if a PST is open for reading only.public FolderInfo addSubFolder(String name, String containerClass)
Adds the new subfolder.
name
- The name of subfolder.containerClass
- Container class of the sub-Folder object.
com.aspose.email.ms.System.NotImplementedException
- throws, if a PST file version is ANSI.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if a subfolder name is null or empty.
IllegalStateException
- throws, if a PST is open for reading only.public String addMessage(MapiMessage message)
Adds a new message into folder.
message
- The message necessary to add.
com.aspose.email.ms.System.NotImplementedException
- throws, if a PST file version is ANSI.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if a message to add is null.
IllegalStateException
- throws, if a PST is open for reading only.public String addMapiMessageItem(IMapiMessageItem item)
Adds the IMapiMessageItem object into folder.
item
- The item necessary to add.
com.aspose.email.ms.System.NotImplementedException
- throws, if a PST file version is ANSI.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if an item to add is null.
IllegalStateException
- throws, if a PST is open for reading only.
UnsupportedOperationException
- Thrown when MessageClass doesn't belong to IPM.Note, IPM.StickyNote,
IPM.Contact, IPM.Activity, IPM.Appointment, IPM.Schedule.meeting, IPM.Task.
IllegalStateException
- Thrown when MessageClass doesn't correspond to the folder's ContainerClass.public void deleteChildItem(byte[] entryId)
Deletes the item (folder or message) by it's entryId.
entryId
- The entry id.
com.aspose.email.ms.System.IllegalArgumentException
- throws, if entryId is null.
IllegalStateException
- throws, if the item doesn't belong to the folder
or the item can't be deleted
or enrtyID has the incorrect value.
IllegalStateException
- throws, if a PST is open for reading only.public void changeDisplayName(String newName)
Changes the display name.
newName
- A new name.
IllegalStateException
- throws, if a PST is open for reading only.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |