edu.uoc.tfc.dbmodel.security
Class UserDaoImpl

java.lang.Object
  extended by org.springframework.dao.support.DaoSupport
      extended by org.springframework.orm.hibernate3.support.HibernateDaoSupport
          extended by edu.uoc.tfc.dbmodel.security.UserDaoBase
              extended by edu.uoc.tfc.dbmodel.security.UserDaoImpl
All Implemented Interfaces:
UserDao, org.springframework.beans.factory.InitializingBean

public class UserDaoImpl
extends UserDaoBase

See Also:
User

Field Summary
 
Fields inherited from interface edu.uoc.tfc.dbmodel.security.UserDao
TRANSFORM_NONE, TRANSFORM_USERVO
 
Constructor Summary
UserDaoImpl()
           
 
Method Summary
 java.util.Collection findUsersByCriteria(CriteriaUserVO criteriaUser)
           Cerca un conjunt d'usuaris a partir d'un criteri de cerca
 java.util.Collection findUsersByCriteria(int transform, CriteriaUserVO criteriaUser)
           Does the same thing as UserDao.findUsersByCriteria(edu.uoc.tfc.dto.security.CriteriaUserVO) with an additional flag called transform.
 java.util.Collection findUsersByCriteria(int transform, int pageNumber, int pageSize, CriteriaUserVO criteriaUser)
           Does the same thing as #findUsersByCriteria(int, String, edu.uoc.tfc.dto.security.CriteriaUserVO) with an additional two arguments called pageNumber and pageSize.
 UserVO toUserVO(User entity)
          Converts this DAO's entity to an object of type UserVO.
 void toUserVO(User source, UserVO target)
          Copies the fields of the specified entity to the target value object.
 User userVOToEntity(UserVO userVO)
          Converts an instance of type UserVO to this DAO's entity.
 void userVOToEntity(UserVO source, User target, boolean copyIfNull)
          Copies the fields of UserVO to the specified entity.
 
Methods inherited from class edu.uoc.tfc.dbmodel.security.UserDaoBase
create, create, create, create, create, create, create, create, findUserByUserId, findUserByUserId, findUserByUserId, findUserByUserId, load, load, loadAll, loadAll, loadAll, loadAll, remove, remove, remove, search, search, search, search, toEntities, toUserVOArray, toUserVOCollection, update, update, userVOToEntityCollection
 
Methods inherited from class org.springframework.orm.hibernate3.support.HibernateDaoSupport
getHibernateTemplate, getSessionFactory, setHibernateTemplate, setSessionFactory
 
Methods inherited from class org.springframework.dao.support.DaoSupport
afterPropertiesSet
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserDaoImpl

public UserDaoImpl()
Method Detail

toUserVO

public void toUserVO(User source,
                     UserVO target)
Description copied from interface: UserDao
Copies the fields of the specified entity to the target value object. This method is similar to toUserVO(), but it does not handle any attributes in the target value object that are "read-only" (as those do not have setter methods exposed).

Specified by:
toUserVO in interface UserDao
Overrides:
toUserVO in class UserDaoBase
See Also:
UserDao.toUserVO(edu.uoc.tfc.dbmodel.security.User, edu.uoc.tfc.dto.security.UserVO)

toUserVO

public UserVO toUserVO(User entity)
Description copied from interface: UserDao
Converts this DAO's entity to an object of type UserVO.

Specified by:
toUserVO in interface UserDao
Overrides:
toUserVO in class UserDaoBase
See Also:
UserDao.toUserVO(edu.uoc.tfc.dbmodel.security.User)

userVOToEntity

public User userVOToEntity(UserVO userVO)
Description copied from interface: UserDao
Converts an instance of type UserVO to this DAO's entity.

See Also:
UserDao.userVOToEntity(edu.uoc.tfc.dto.security.UserVO)

userVOToEntity

public void userVOToEntity(UserVO source,
                           User target,
                           boolean copyIfNull)
Description copied from interface: UserDao
Copies the fields of UserVO to the specified entity.

Specified by:
userVOToEntity in interface UserDao
Overrides:
userVOToEntity in class UserDaoBase
copyIfNull - If FALSE, the value object's field will not be copied to the entity if the value is NULL. If TRUE, it will be copied regardless of its value.
See Also:
edu.uoc.tfc.dbmodel.security.UserDao#userVOToEntity(edu.uoc.tfc.dto.security.UserVO, edu.uoc.tfc.dbmodel.security.User)

findUsersByCriteria

public java.util.Collection findUsersByCriteria(CriteriaUserVO criteriaUser)
Description copied from interface: UserDao

Cerca un conjunt d'usuaris a partir d'un criteri de cerca

Specified by:
findUsersByCriteria in interface UserDao
Overrides:
findUsersByCriteria in class UserDaoBase
See Also:
UserDao.findUsersByCriteria(edu.uoc.tfc.dto.security.CriteriaUserVO)

findUsersByCriteria

public java.util.Collection findUsersByCriteria(int transform,
                                                CriteriaUserVO criteriaUser)
Description copied from interface: UserDao

Does the same thing as UserDao.findUsersByCriteria(edu.uoc.tfc.dto.security.CriteriaUserVO) with an additional flag called transform. If this flag is set to TRANSFORM_NONE then finder results will NOT be transformed during retrieval. If this flag is any of the other constants defined here then finder results WILL BE passed through an operation which can optionally transform the entities (into value objects for example). By default, transformation does not occur.

Specified by:
findUsersByCriteria in interface UserDao
Overrides:
findUsersByCriteria in class UserDaoBase
See Also:
UserDao.findUsersByCriteria(int, edu.uoc.tfc.dto.security.CriteriaUserVO)

findUsersByCriteria

public java.util.Collection findUsersByCriteria(int transform,
                                                int pageNumber,
                                                int pageSize,
                                                CriteriaUserVO criteriaUser)
Description copied from interface: UserDao

Does the same thing as #findUsersByCriteria(int, String, edu.uoc.tfc.dto.security.CriteriaUserVO) with an additional two arguments called pageNumber and pageSize. The pageNumber argument allows you to specify the page number when you are paging the results and the pageSize allows you to specify the size of the page retrieved.

Specified by:
findUsersByCriteria in interface UserDao
Overrides:
findUsersByCriteria in class UserDaoBase
See Also:
edu.uoc.tfc.dbmodel.security.UserDao#findUsersByCriteria(int, java.lang.String, int, int, edu.uoc.tfc.dto.security.CriteriaUserVO)