edu.nrao.sss.dao.proposal
Class HibernateProposalDao
java.lang.Object
edu.nrao.sss.dao.HibernateDao
edu.nrao.sss.dao.proposal.HibernateProposalDao
public class HibernateProposalDao
- extends HibernateDao
A Hibernate
data access object for Proposal
s.
- Since:
- 2006-02-24
- Version:
- 1.1
Methods inherited from class edu.nrao.sss.dao.HibernateDao |
addDaoListener, beginTransaction, closeSession, commitTransaction, destroyAllFactories, destroyFactory, fireRollbackEvent, getConfigurationFileName, getInterceptor, getSession, getSessionFactory, removeDaoListeners, rollbackTransaction, setConfigurationFileName, setInterceptor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HibernateProposalDao
public HibernateProposalDao()
- empty no-arg constructor
- See Also:
HibernateDao
HibernateProposalDao
public HibernateProposalDao(String cfg,
org.hibernate.Interceptor i)
- See Also:
HibernateDao
findById
public Proposal findById(long id)
throws RepositoryException
- Returns:
- null if a Proposal with the provided id doesn't exist.
- Throws:
RepositoryException
findByCode
public Proposal findByCode(String proposalId)
throws RepositoryException
- Returns:
- null if a Proposal with the provided id doesn't exist.
- Throws:
RepositoryException
findByUserId
public List<Proposal> findByUserId(long uid)
throws RepositoryException
- Returns:
- a List (possibly empty) of Proposals that uid is an editor of.
This method does not return null.
- Throws:
RepositoryException
findProposals
public List<Proposal> findProposals(Long userId,
ProposalStatus status)
throws RepositoryException
- Throws:
RepositoryException
findProposals
public List<Proposal> findProposals(ProposalStatus status)
throws RepositoryException
- Throws:
RepositoryException
getAllProposals
public List<Proposal> getAllProposals()
throws RepositoryException
- Throws:
RepositoryException
save
public void save(Proposal proposal)
throws RepositoryException
- Throws:
RepositoryException
deleteById
public void deleteById(long id)
throws RepositoryException
- Throws:
RepositoryException
delete
public void delete(Proposal proposal)
throws RepositoryException
- Silently ignores being passed null and transient objects.
- Throws:
RepositoryException
cancelChanges
public void cancelChanges(Proposal p)
throws RepositoryException
- Throws:
RepositoryException
Copyright © 2009. All Rights Reserved.