public class InMemoryUidProvider extends Object implements UidProvider<Long>
| Constructor and Description |
|---|
InMemoryUidProvider() |
| Modifier and Type | Method and Description |
|---|---|
long |
lastUid(MailboxSession session,
Mailbox<Long> mailbox)
Return the last uid which were used for storing a Message in the
Mailbox |
long |
nextUid(MailboxSession session,
Mailbox<Long> mailbox)
Return the next uid which can be used while append a Message to the
Mailbox. |
public long nextUid(MailboxSession session, Mailbox<Long> mailbox) throws MailboxException
UidProviderMailbox.
Its important that the returned uid is higher then the last used and that the next call of this method does return a higher
onenextUid in interface UidProvider<Long>MailboxExceptionpublic long lastUid(MailboxSession session, Mailbox<Long> mailbox) throws MailboxException
UidProviderMailboxlastUid in interface UidProvider<Long>MailboxExceptionCopyright © 2010-2012 The Apache Software Foundation. All Rights Reserved.