it.eng.spagobi.commons.dao
Class DomainDAOHibImpl

java.lang.Object
  extended by it.eng.spagobi.commons.dao.AbstractHibernateDAO
      extended by it.eng.spagobi.commons.dao.DomainDAOHibImpl
All Implemented Interfaces:
IDomainDAO

public class DomainDAOHibImpl
extends AbstractHibernateDAO
implements IDomainDAO

Defines the Hibernate implementations for all DAO methods, for a domain.

Author:
zoppello

Constructor Summary
DomainDAOHibImpl()
           
 
Method Summary
 Domain loadDomainByCodeAndValue(java.lang.String codeDomain, java.lang.String codeValue)
          Load domain by code and value.
 Domain loadDomainById(java.lang.Integer id)
          Load domain by id.
 java.util.List loadListDomains()
          Loads all possible domain, storing each of them into a Domain and after putting all objects into a list, which is returned.
 java.util.List loadListDomainsByType(java.lang.String domainType)
          Load list domains by type.
 SbiDomains loadSbiDomainByCodeAndValue(java.lang.String codeDomain, java.lang.String codeValue)
          Load domain by code and value.
 Domain toDomain(SbiDomains hibDomain)
          From the hibernate domain object at input, gives the corrispondent Domain object.
 
Methods inherited from class it.eng.spagobi.commons.dao.AbstractHibernateDAO
getSession, logException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DomainDAOHibImpl

public DomainDAOHibImpl()
Method Detail

loadListDomainsByType

public java.util.List loadListDomainsByType(java.lang.String domainType)
                                     throws it.eng.spago.error.EMFUserError
Load list domains by type.

Specified by:
loadListDomainsByType in interface IDomainDAO
Parameters:
domainType - the domain type
Returns:
the list
Throws:
it.eng.spago.error.EMFUserError - the EMF user error
See Also:
IDomainDAO.loadListDomainsByType(java.lang.String)

loadDomainByCodeAndValue

public Domain loadDomainByCodeAndValue(java.lang.String codeDomain,
                                       java.lang.String codeValue)
                                throws it.eng.spago.error.EMFUserError
Load domain by code and value.

Specified by:
loadDomainByCodeAndValue in interface IDomainDAO
Parameters:
codeDomain - the code domain
codeValue - the code value
Returns:
the domain
Throws:
it.eng.spago.error.EMFUserError - the EMF user error
See Also:
IDomainDAO.loadDomainByCodeAndValue(java.lang.String, java.lang.String)

loadSbiDomainByCodeAndValue

public SbiDomains loadSbiDomainByCodeAndValue(java.lang.String codeDomain,
                                              java.lang.String codeValue)
                                       throws it.eng.spago.error.EMFUserError
Load domain by code and value.

Specified by:
loadSbiDomainByCodeAndValue in interface IDomainDAO
Parameters:
codeDomain - the code domain
codeValue - the code value
Returns:
the domain
Throws:
it.eng.spago.error.EMFUserError - the EMF user error
See Also:
IDomainDAO.loadDomainByCodeAndValue(java.lang.String, java.lang.String)

toDomain

public Domain toDomain(SbiDomains hibDomain)
From the hibernate domain object at input, gives the corrispondent Domain object.

Parameters:
hibDomain - The hybernate Domain object
Returns:
The corrispondent Domain

loadDomainById

public Domain loadDomainById(java.lang.Integer id)
                      throws it.eng.spago.error.EMFUserError
Load domain by id.

Specified by:
loadDomainById in interface IDomainDAO
Parameters:
id - the id
Returns:
the domain
Throws:
it.eng.spago.error.EMFUserError - the EMF user error
See Also:
IDomainDAO.loadDomainById(java.lang.Integer)

loadListDomains

public java.util.List loadListDomains()
                               throws it.eng.spago.error.EMFUserError
Description copied from interface: IDomainDAO
Loads all possible domain, storing each of them into a Domain and after putting all objects into a list, which is returned.

Specified by:
loadListDomains in interface IDomainDAO
Returns:
The list of all domains
Throws:
it.eng.spago.error.EMFUserError - If an Exception occurred