org.apache.james.domainlist.jpa
Class JPADomainList

java.lang.Object
  extended by org.apache.james.domainlist.lib.AbstractDomainList
      extended by org.apache.james.domainlist.jpa.JPADomainList
All Implemented Interfaces:
DomainList, Configurable, LogEnabled

public class JPADomainList
extends AbstractDomainList

JPA implementation of the DomainList.
This implementation is compatible with the JDBCDomainList, meaning same database schema can be reused.


Constructor Summary
JPADomainList()
           
 
Method Summary
 void addDomain(String domain)
           
 boolean containsDomain(String domain)
           
protected  List<String> getDomainListInternal()
           
 void init()
           
 void removeDomain(String domain)
           
 void setEntityManagerFactory(javax.persistence.EntityManagerFactory entityManagerFactory)
          Set the entity manager to use.
 
Methods inherited from class org.apache.james.domainlist.lib.AbstractDomainList
configure, getDefaultDomain, getDNSServer, getDomains, getLogger, setAutoDetect, setAutoDetectIP, setDNSService, setLog
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JPADomainList

public JPADomainList()
Method Detail

setEntityManagerFactory

public void setEntityManagerFactory(javax.persistence.EntityManagerFactory entityManagerFactory)
Set the entity manager to use.

Parameters:
entityManagerFactory -

init

@PostConstruct
public void init()

getDomainListInternal

protected List<String> getDomainListInternal()
                                      throws DomainListException
Specified by:
getDomainListInternal in class AbstractDomainList
Throws:
DomainListException
See Also:
AbstractDomainList.getDomainListInternal()

containsDomain

public boolean containsDomain(String domain)
                       throws DomainListException
Throws:
DomainListException
See Also:
DomainList.containsDomain(java.lang.String)

addDomain

public void addDomain(String domain)
               throws DomainListException
Throws:
DomainListException
See Also:
DomainList.addDomain(java.lang.String)

removeDomain

public void removeDomain(String domain)
                  throws DomainListException
Throws:
DomainListException
See Also:
DomainList.removeDomain(java.lang.String)


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