lumis.portal.service
Class ServiceDaoHib

Package class diagram package ServiceDaoHib
java.lang.Object
  extended by lumis.portal.dao.hibernate.GenericHibernateManualUpdateDao<ServiceConfig,String>
      extended by lumis.portal.service.ServiceDaoHib
All Implemented Interfaces:
IServiceDao

public class ServiceDaoHib
extends GenericHibernateManualUpdateDao<ServiceConfig,String>
implements IServiceDao

Class responsible for persisting ServiceConfig information.

Since:
4.0.0

Constructor Summary
ServiceDaoHib()
           
 
Method Summary
 void add(ServiceConfig serviceConfig, ITransaction transaction)
          Adds the bean to the persistence layer.
 void clearCache()
          Clears the caches in this DAO.
 boolean delete(String serviceId, ITransaction transaction)
          Deletes the bean with the given id from persistence.
 ServiceConfig get(String serviceId, ITransaction transaction)
          Returns the bean with the given id.
 ServiceConfig getByBaseUrl(String baseUrl, ITransaction daoTransaction)
          Returns a ServiceConfig by it's baseUrl.
protected  String getIdentifier(ServiceConfig serviceConfig)
           
 Collection<String> getServicesIds(boolean getInstantiableServicesOnly, ITransaction transaction)
          Get the ids of services.
 void update(ServiceConfig serviceConfig, ITransaction transaction)
          Update the service.
 
Methods inherited from class lumis.portal.dao.hibernate.GenericHibernateManualUpdateDao
addOrUpdate, evict, findByCriteria, findByCriteria, getPersistentClass, setReadOnly
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServiceDaoHib

public ServiceDaoHib()
Method Detail

getIdentifier

protected String getIdentifier(ServiceConfig serviceConfig)
Specified by:
getIdentifier in class GenericHibernateManualUpdateDao<ServiceConfig,String>

add

public void add(ServiceConfig serviceConfig,
                ITransaction transaction)
         throws DaoException,
                PortalException
Description copied from class: GenericHibernateManualUpdateDao
Adds the bean to the persistence layer.

Specified by:
add in interface IServiceDao
Overrides:
add in class GenericHibernateManualUpdateDao<ServiceConfig,String>
Parameters:
serviceConfig - the bean to be added.
transaction - the transaction for persistence access.
Throws:
DaoException
PortalException

update

public void update(ServiceConfig serviceConfig,
                   ITransaction transaction)
            throws DaoException,
                   PortalException
Description copied from interface: IServiceDao
Update the service.

Specified by:
update in interface IServiceDao
Overrides:
update in class GenericHibernateManualUpdateDao<ServiceConfig,String>
Throws:
DaoException
PortalException

get

public ServiceConfig get(String serviceId,
                         ITransaction transaction)
                  throws DaoException,
                         PortalException
Description copied from class: GenericHibernateManualUpdateDao
Returns the bean with the given id. The bean is set as read-only, so changes on it won't persist automatically.

Specified by:
get in interface IServiceDao
Overrides:
get in class GenericHibernateManualUpdateDao<ServiceConfig,String>
Parameters:
serviceId - the bean's id.
transaction - the transaction for persistence access. Must be a ITransactionHibernate.
Returns:
the bean.
Throws:
DaoException
PortalException

delete

public boolean delete(String serviceId,
                      ITransaction transaction)
               throws DaoException,
                      PortalException
Description copied from class: GenericHibernateManualUpdateDao
Deletes the bean with the given id from persistence.

Specified by:
delete in interface IServiceDao
Overrides:
delete in class GenericHibernateManualUpdateDao<ServiceConfig,String>
Parameters:
serviceId - the bean's id.
transaction - the transaction for persistence access. Must be a ITransactionHibernate.
Returns:
true if the bean was deleted, or false if it did not exist
Throws:
DaoException
PortalException

getServicesIds

public Collection<String> getServicesIds(boolean getInstantiableServicesOnly,
                                         ITransaction transaction)
                                  throws DaoException,
                                         PortalException
Description copied from interface: IServiceDao
Get the ids of services.

Specified by:
getServicesIds in interface IServiceDao
Returns:
Throws:
ManagerException
PortalException
DaoException

getByBaseUrl

public ServiceConfig getByBaseUrl(String baseUrl,
                                  ITransaction daoTransaction)
                           throws DaoException,
                                  PortalException
Description copied from interface: IServiceDao
Returns a ServiceConfig by it's baseUrl.

Specified by:
getByBaseUrl in interface IServiceDao
Returns:
Throws:
DaoException
PortalException

clearCache

public void clearCache()
                throws PortalException
Description copied from interface: IServiceDao
Clears the caches in this DAO.

Specified by:
clearCache in interface IServiceDao
Throws:
PortalException


Lumisportal  6.2.0.120405 - Copyright © 2006–2012 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.