|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface MessagingAccountAccess
MessagingAccountAccess - Provides access to a messaging account.
| Method Summary | |
|---|---|
int |
getAccountId()
Gets the account identifier of this access. |
MessagingFolderAccess |
getFolderAccess()
Gets the folder access for associated account. |
MessagingMessageAccess |
getMessageAccess()
Gets the message access for associated account. |
MessagingFolder |
getRootFolder()
Convenience method to obtain root folder in a fast way; meaning no default folder check is performed which is not necessary to return the root folder. |
| Methods inherited from interface com.openexchange.messaging.MessagingResource |
|---|
cacheable, close, connect, isConnected, ping |
| Method Detail |
|---|
int getAccountId()
MessagingMessageAccess getMessageAccess()
throws MessagingException
MessagingException - If message access cannot be returned
MessagingFolderAccess getFolderAccess()
throws MessagingException
MessagingException - If folder access cannot be returned
MessagingFolder getRootFolder()
throws MessagingException
The same result is yielded through calling getFolderAccess().getRootFolder() on a connected
MessagingFolderAccess.
Since this account access instance is connected if not already done before, the MessagingResource.close() operation should be invoked
afterwards:
final MessagingMessageAccess access = MailAccess.getInstance(session);
final MessagingFolder rootFolder = access.getRootFolder();
try {
// Do something with root folder
} finally {
access.close();
}
MessagingException - If returning the root folder fails
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||