org.apache.james.mailbox
Interface MailboxListener

All Known Implementing Classes:
MailboxEventDispatcher

public interface MailboxListener

Listens to Mailbox events. Note that listeners may be removed asynchronously. When isClosed() returns true, the listener may be removed from the mailbox by the dispatcher.


Nested Class Summary
static class MailboxListener.Added
          A mailbox event related to added message
static class MailboxListener.Event
          A mailbox event.
static class MailboxListener.Expunged
           
static class MailboxListener.FlagsUpdated
          A mailbox event related to updated flags
static class MailboxListener.MailboxDeletionEvent
          Indicates that mailbox has been deleted.
static class MailboxListener.MailboxRenamed
          Indicates that a mailbox has been renamed.
static class MailboxListener.MessageEvent
          A mailbox event related to a message.
 
Method Summary
 void event(MailboxListener.Event event)
          Informs this listener about the given event.
 boolean isClosed()
          Is this listener closed?
 

Method Detail

event

void event(MailboxListener.Event event)
Informs this listener about the given event.

Parameters:
event - not null

isClosed

boolean isClosed()
Is this listener closed? Closed listeners may be unsubscribed.

Returns:
true when closed, false when open


Copyright © 2002-2010 The Apache Software Foundation. All Rights Reserved.