org.apache.james.mailbox
Interface SubscriptionManager

All Superinterfaces:
RequestAware

public interface SubscriptionManager
extends RequestAware

Subscribes users.


Method Summary
 void subscribe(MailboxSession session, java.lang.String mailbox)
          Subscribes the user in the session to the given mailbox.
 java.util.Collection<java.lang.String> subscriptions(MailboxSession session)
          Finds all subscriptions for the user in the session.
 void unsubscribe(MailboxSession session, java.lang.String mailbox)
          Unsubscribes the user in the session from the given mailbox.
 
Methods inherited from interface org.apache.james.mailbox.RequestAware
endProcessingRequest, startProcessingRequest
 

Method Detail

subscribe

void subscribe(MailboxSession session,
               java.lang.String mailbox)
               throws SubscriptionException
Subscribes the user in the session to the given mailbox.

Parameters:
session - not null
mailbox - not null
Throws:
SubscriptionException - when subscription fails

subscriptions

java.util.Collection<java.lang.String> subscriptions(MailboxSession session)
                                                     throws SubscriptionException
Finds all subscriptions for the user in the session.

Parameters:
user - not null
Returns:
not null
Throws:
SubscriptionException - when subscriptions cannot be read

unsubscribe

void unsubscribe(MailboxSession session,
                 java.lang.String mailbox)
                 throws SubscriptionException
Unsubscribes the user in the session from the given mailbox.

Parameters:
session - not null
mailbox - not null
Throws:
SubscriptionException - when subscriptions cannot be read


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