public abstract class AbstractMailRepository extends Object implements MailRepository, LogEnabled, Configurable
| Modifier and Type | Field and Description |
|---|---|
protected static boolean |
DEEP_DEBUG
Whether 'deep debugging' is turned on.
|
| Constructor and Description |
|---|
AbstractMailRepository() |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(org.apache.commons.configuration.HierarchicalConfiguration configuration)
Configure the object.
|
protected void |
doConfigure(org.apache.commons.configuration.HierarchicalConfiguration config) |
protected org.slf4j.Logger |
getLogger() |
protected abstract void |
internalRemove(String key) |
protected abstract void |
internalStore(org.apache.mailet.Mail mc) |
boolean |
lock(String key)
Obtains a lock on a message identified by key
|
void |
remove(Collection<org.apache.mailet.Mail> mails)
Remove an Collection of mails from the repository
|
void |
remove(org.apache.mailet.Mail mail)
Removes a specified message
|
void |
remove(String key)
Removes a message identified by key.
|
void |
setLog(org.slf4j.Logger logger)
Sets the service log.
|
void |
store(org.apache.mailet.Mail mc)
Stores a message in this repository.
|
boolean |
unlock(String key)
Releases a lock on a message identified the key
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitlist, retrieveprotected static final boolean DEEP_DEBUG
public void setLog(org.slf4j.Logger logger)
LogEnabledsetLog in interface LogEnabledlogger - not nullprotected org.slf4j.Logger getLogger()
public void configure(org.apache.commons.configuration.HierarchicalConfiguration configuration)
throws org.apache.commons.configuration.ConfigurationException
Configurableconfigure in interface Configurableorg.apache.commons.configuration.ConfigurationExceptionprotected void doConfigure(org.apache.commons.configuration.HierarchicalConfiguration config)
throws org.apache.commons.configuration.ConfigurationException
org.apache.commons.configuration.ConfigurationExceptionpublic boolean unlock(String key)
MailRepositoryunlock in interface MailRepositorykey - the key of the message to be unlockedMailRepository.unlock(String)public boolean lock(String key)
MailRepositorylock in interface MailRepositorykey - the key of the message to be lockedMailRepository.lock(String)public void store(org.apache.mailet.Mail mc)
throws javax.mail.MessagingException
MailRepositorystore in interface MailRepositorymc - the mail message to storejavax.mail.MessagingExceptionMailRepository.store(Mail)protected abstract void internalStore(org.apache.mailet.Mail mc)
throws javax.mail.MessagingException,
IOException
javax.mail.MessagingExceptionIOExceptionstore(Mail)public void remove(org.apache.mailet.Mail mail)
throws javax.mail.MessagingException
MailRepositoryremove in interface MailRepositorymail - the message to be removed from the repositoryjavax.mail.MessagingExceptionMailRepository.remove(Mail)public void remove(Collection<org.apache.mailet.Mail> mails) throws javax.mail.MessagingException
MailRepositoryremove in interface MailRepositorymails - The Collection of MailImpl's to deletejavax.mail.MessagingExceptionMailRepository.remove(Collection)public void remove(String key) throws javax.mail.MessagingException
MailRepositoryremove in interface MailRepositorykey - the key of the message to be removed from the repositoryjavax.mail.MessagingExceptionMailRepository.remove(String)protected abstract void internalRemove(String key) throws javax.mail.MessagingException
javax.mail.MessagingExceptionremove(String)Copyright © 2002-2012 The Apache Software Foundation. All Rights Reserved.