Nuxeo Enterprise Platform 5.4

org.nuxeo.cm.ejb
Class MailboxManagementBean

java.lang.Object
  extended by org.nuxeo.cm.ejb.MailboxManagementBean
All Implemented Interfaces:
Serializable, MailboxManagementService

public class MailboxManagementBean
extends Object
implements MailboxManagementService

See Also:
Serialized Form

Constructor Summary
MailboxManagementBean()
           
 
Method Summary
 List<Mailbox> createPersonalMailboxes(org.nuxeo.ecm.core.api.CoreSession session, String userId)
          Create the personal Mailbox with the registered
 Mailbox getMailbox(org.nuxeo.ecm.core.api.CoreSession session, String muid)
          Returns the mailbox with given unique identifier.
 List<Mailbox> getMailboxes(org.nuxeo.ecm.core.api.CoreSession session, List<String> muids)
          Returns the mailboxes with given unique identifiers.
 List<MailboxHeader> getMailboxesHeaders(org.nuxeo.ecm.core.api.CoreSession session, List<String> muids)
          Returns the mailboxes with given unique identifiers and a session.
 MailboxHeader getMailboxHeader(org.nuxeo.ecm.core.api.CoreSession session, String mailboxId)
           
 List<Mailbox> getUserMailboxes(org.nuxeo.ecm.core.api.CoreSession session, String userId)
          Returns all mailboxes for given user.
 Mailbox getUserPersonalMailbox(org.nuxeo.ecm.core.api.CoreSession session, String userId)
          Returns the personal mailbox of the given user.
 Mailbox getUserPersonalMailboxForEmail(org.nuxeo.ecm.core.api.CoreSession session, String email)
          Returns a mailbox for given email
 String getUserPersonalMailboxId(String user)
          Returns the personal mailbox id for this user.
 boolean hasMailbox(org.nuxeo.ecm.core.api.CoreSession session, String muid)
          Returns true if a mailbox with given id exists
 boolean hasUserPersonalMailbox(org.nuxeo.ecm.core.api.CoreSession session, String userId)
          Test if the user has a personal mailbox created
 List<MailboxHeader> searchMailboxes(org.nuxeo.ecm.core.api.CoreSession session, String pattern, String type)
          Search mailboxes with given pattern
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MailboxManagementBean

public MailboxManagementBean()
Method Detail

getMailbox

public Mailbox getMailbox(org.nuxeo.ecm.core.api.CoreSession session,
                          String muid)
Description copied from interface: MailboxManagementService
Returns the mailbox with given unique identifier.

Specified by:
getMailbox in interface MailboxManagementService
muid - User id

hasMailbox

public boolean hasMailbox(org.nuxeo.ecm.core.api.CoreSession session,
                          String muid)
Description copied from interface: MailboxManagementService
Returns true if a mailbox with given id exists

Specified by:
hasMailbox in interface MailboxManagementService
muid - mailbox id

getMailboxesHeaders

public List<MailboxHeader> getMailboxesHeaders(org.nuxeo.ecm.core.api.CoreSession session,
                                               List<String> muids)
Description copied from interface: MailboxManagementService
Returns the mailboxes with given unique identifiers and a session. Giving session can be helpful when you already are in an unrestrictedSessionRunner.

Specified by:
getMailboxesHeaders in interface MailboxManagementService
Returns:

getMailboxes

public List<Mailbox> getMailboxes(org.nuxeo.ecm.core.api.CoreSession session,
                                  List<String> muids)
Description copied from interface: MailboxManagementService
Returns the mailboxes with given unique identifiers.

Specified by:
getMailboxes in interface MailboxManagementService
Parameters:
session - a Core Session
muids - Users ids

getUserPersonalMailboxId

public String getUserPersonalMailboxId(String user)
Description copied from interface: MailboxManagementService
Returns the personal mailbox id for this user.

Specified by:
getUserPersonalMailboxId in interface MailboxManagementService
Parameters:
user - User id

getUserMailboxes

public List<Mailbox> getUserMailboxes(org.nuxeo.ecm.core.api.CoreSession session,
                                      String userId)
Description copied from interface: MailboxManagementService
Returns all mailboxes for given user. Creates a personal mailbox for real users if needed.

Specified by:
getUserMailboxes in interface MailboxManagementService
userId - User id

getUserPersonalMailbox

public Mailbox getUserPersonalMailbox(org.nuxeo.ecm.core.api.CoreSession session,
                                      String userId)
Description copied from interface: MailboxManagementService
Returns the personal mailbox of the given user.

Specified by:
getUserPersonalMailbox in interface MailboxManagementService
userId - User id

getUserPersonalMailboxForEmail

public Mailbox getUserPersonalMailboxForEmail(org.nuxeo.ecm.core.api.CoreSession session,
                                              String email)
Description copied from interface: MailboxManagementService
Returns a mailbox for given email

Specified by:
getUserPersonalMailboxForEmail in interface MailboxManagementService

searchMailboxes

public List<MailboxHeader> searchMailboxes(org.nuxeo.ecm.core.api.CoreSession session,
                                           String pattern,
                                           String type)
Description copied from interface: MailboxManagementService
Search mailboxes with given pattern

Specified by:
searchMailboxes in interface MailboxManagementService
pattern - matching the box title
type - mailbox type (generic, personal, etc... or null to match all)

createPersonalMailboxes

public List<Mailbox> createPersonalMailboxes(org.nuxeo.ecm.core.api.CoreSession session,
                                             String userId)
Description copied from interface: MailboxManagementService
Create the personal Mailbox with the registered

Specified by:
createPersonalMailboxes in interface MailboxManagementService
Returns:
personal mailbox list.

hasUserPersonalMailbox

public boolean hasUserPersonalMailbox(org.nuxeo.ecm.core.api.CoreSession session,
                                      String userId)
Description copied from interface: MailboxManagementService
Test if the user has a personal mailbox created

Specified by:
hasUserPersonalMailbox in interface MailboxManagementService
Returns:
true if the user has a personal mailbox

getMailboxHeader

public MailboxHeader getMailboxHeader(org.nuxeo.ecm.core.api.CoreSession session,
                                      String mailboxId)
Specified by:
getMailboxHeader in interface MailboxManagementService

Nuxeo Enterprise Platform 5.4

Copyright © 2011 Nuxeo SAS. All Rights Reserved.