1 17 18 package org.apache.james.imapserver; 19 20 import org.apache.james.imapserver.AccessControlException; 21 import org.apache.james.imapserver.AuthorizationException; 22 23 import java.util.Collection ; 24 import java.util.List ; 25 26 41 public interface Host 42 { 43 44 String ROLE = "org.apache.james.imapserver.Host"; 45 46 String IMAP_HOST = "IMAP_HOST"; 47 48 57 boolean isHomeServer( String username ); 58 59 68 boolean hasLocalAccess( String username ); 69 70 82 ACLMailbox getMailbox( String user, String mailboxName ) 83 throws AccessControlException, MailboxException; 84 85 86 108 ACLMailbox createMailbox( String user, String mailboxName ) 109 throws AccessControlException, AuthorizationException, MailboxException; 110 111 112 128 boolean deleteMailbox( String user, String mailboxName ) 129 throws MailboxException, AuthorizationException, AccessControlException; 130 131 132 155 boolean renameMailbox( String user, 156 String oldMailboxName, 157 String newMailboxName ) 158 throws MailboxException, AuthorizationException; 159 160 166 void releaseMailbox( String user, ACLMailbox mbox ); 167 168 175 String getDefaultNamespace( String username ); 176 177 178 185 187 188 229 Collection listMailboxes( String username, 230 String referenceName, 231 String mailboxName, 232 boolean subscribedOnly ) 233 throws MailboxException, AccessControlException; 234 235 246 boolean subscribe( String username, String mailbox ) 247 throws MailboxException, AccessControlException; 248 249 256 boolean unsubscribe( String username, String mailbox ) 257 throws MailboxException, AccessControlException; 258 259 279 String getMailboxStatus( String username, 280 String mailboxName, 281 List dataItems ) 282 throws MailboxException, AccessControlException; 283 284 285 boolean createPrivateMailAccount( String username ); 286 } 287 288 | Popular Tags |