public class HibernateConditionDAO extends Object implements ConditionDAO
ConditionDAO| Constructor and Description |
|---|
HibernateConditionDAO() |
| Modifier and Type | Method and Description |
|---|---|
void |
deleteCondition(Condition condition)
Removes a condition from the database
|
List<Condition> |
getActiveConditions(Patient patient)
Gets all active conditions related to the specified patient.
|
List<Condition> |
getAllConditions(Patient patient) |
Condition |
getCondition(Integer conditionId)
Gets the condition with the specified id.
|
Condition |
getConditionByUuid(String uuid)
Gets the condition by its UUID.
|
List<Condition> |
getConditionsByEncounter(Encounter encounter) |
Condition |
saveCondition(Condition condition)
Saves the condition.
|
void |
setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Set session factory
|
public void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
sessionFactory - public Condition getCondition(Integer conditionId)
getCondition in interface ConditionDAOconditionId - the id to search for in the database.public Condition getConditionByUuid(String uuid)
getConditionByUuid in interface ConditionDAOuuid - the UUID to search for in the database.public List<Condition> getConditionsByEncounter(Encounter encounter) throws APIException
getConditionsByEncounter in interface ConditionDAOAPIExceptionConditionService.getConditionsByEncounter(Encounter)public List<Condition> getActiveConditions(Patient patient)
getActiveConditions in interface ConditionDAOpatient - the patient whose active conditions are being queried.public List<Condition> getAllConditions(Patient patient)
getAllConditions in interface ConditionDAOConditionService.getAllConditions(Patient)public void deleteCondition(Condition condition) throws DAOException
deleteCondition in interface ConditionDAOcondition - the condition to be deletedDAOExceptionpublic Condition saveCondition(Condition condition)
saveCondition in interface ConditionDAOcondition - the condition to save.Copyright © 2024 OpenMRS Inc.. All rights reserved.