Java 类ims.emergency.vo.domain.EmergencyAttendanceForObsPatientAssessmentVoAssembler 实例源码

项目:AvoinApotti    文件:ObsPatientAssessmentCcImpl.java   
public ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo save(ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo emergencyAttForObsPatAssessmentToSave) throws ims.domain.exceptions.StaleObjectException
{
    if (emergencyAttForObsPatAssessmentToSave == null)
        throw new CodingRuntimeException("Cannot save null emergencyAttForObsPatAssessmentToSave ");
    if (!emergencyAttForObsPatAssessmentToSave.isValidated())
    {
        throw new DomainRuntimeException("emergencyAttForObsPatAssessmentToSave has not been validated");
    }

    DomainFactory factory = getDomainFactory();
    EmergencyAttendance doEmergencyAttForPatAssessment = EmergencyAttendanceForObsPatientAssessmentVoAssembler.extractEmergencyAttendance(factory, emergencyAttForObsPatAssessmentToSave);

    factory.save(doEmergencyAttForPatAssessment);

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create(doEmergencyAttForPatAssessment);
}
项目:AvoinApotti    文件:ObsPatientAssessmentCcImpl.java   
public EmergencyAttendanceForObsPatientAssessmentVo getEmergencyAttendance(CareContextRefVo careContextRef)
{
    if (careContextRef == null || careContextRef.getID_CareContext() == null)
    {
        throw new CodingRuntimeException("Cannot get PatientAssessment on null Id for CareContext ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();
    hql.append("from EmergencyAttendance as emergAtt where emergAtt.careContext.id = :careContextID ");

    List<?> list = factory.find(hql.toString(), new String[] { "careContextID" }, new Object[] { careContextRef.getID_CareContext() });

    if (list == null || list.size() == 0)
        return null;

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create((EmergencyAttendance) list.get(0));
}
项目:openMAXIMS    文件:ObsPatientAssessmentCcImpl.java   
public ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo save(ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo emergencyAttForObsPatAssessmentToSave) throws ims.domain.exceptions.StaleObjectException
{
    if (emergencyAttForObsPatAssessmentToSave == null)
        throw new CodingRuntimeException("Cannot save null emergencyAttForObsPatAssessmentToSave ");
    if (!emergencyAttForObsPatAssessmentToSave.isValidated())
    {
        throw new DomainRuntimeException("emergencyAttForObsPatAssessmentToSave has not been validated");
    }

    DomainFactory factory = getDomainFactory();
    EmergencyAttendance doEmergencyAttForPatAssessment = EmergencyAttendanceForObsPatientAssessmentVoAssembler.extractEmergencyAttendance(factory, emergencyAttForObsPatAssessmentToSave);

    factory.save(doEmergencyAttForPatAssessment);

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create(doEmergencyAttForPatAssessment);
}
项目:openMAXIMS    文件:ObsPatientAssessmentCcImpl.java   
public EmergencyAttendanceForObsPatientAssessmentVo getEmergencyAttendance(CareContextRefVo careContextRef)
{
    if (careContextRef == null || careContextRef.getID_CareContext() == null)
    {
        throw new CodingRuntimeException("Cannot get PatientAssessment on null Id for CareContext ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();
    hql.append("from EmergencyAttendance as emergAtt where emergAtt.careContext.id = :careContextID ");

    List<?> list = factory.find(hql.toString(), new String[] { "careContextID" }, new Object[] { careContextRef.getID_CareContext() });

    if (list == null || list.size() == 0)
        return null;

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create((EmergencyAttendance) list.get(0));
}
项目:openMAXIMS    文件:ObsPatientAssessmentCcImpl.java   
public ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo save(ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo emergencyAttForObsPatAssessmentToSave) throws ims.domain.exceptions.StaleObjectException
{
    if (emergencyAttForObsPatAssessmentToSave == null)
        throw new CodingRuntimeException("Cannot save null emergencyAttForObsPatAssessmentToSave ");
    if (!emergencyAttForObsPatAssessmentToSave.isValidated())
    {
        throw new DomainRuntimeException("emergencyAttForObsPatAssessmentToSave has not been validated");
    }

    DomainFactory factory = getDomainFactory();
    EmergencyAttendance doEmergencyAttForPatAssessment = EmergencyAttendanceForObsPatientAssessmentVoAssembler.extractEmergencyAttendance(factory, emergencyAttForObsPatAssessmentToSave);

    factory.save(doEmergencyAttForPatAssessment);

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create(doEmergencyAttForPatAssessment);
}
项目:openMAXIMS    文件:ObsPatientAssessmentCcImpl.java   
public EmergencyAttendanceForObsPatientAssessmentVo getEmergencyAttendance(CareContextRefVo careContextRef)
{
    if (careContextRef == null || careContextRef.getID_CareContext() == null)
    {
        throw new CodingRuntimeException("Cannot get PatientAssessment on null Id for CareContext ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();
    hql.append("from EmergencyAttendance as emergAtt where emergAtt.careContext.id = :careContextID ");

    List<?> list = factory.find(hql.toString(), new String[] { "careContextID" }, new Object[] { careContextRef.getID_CareContext() });

    if (list == null || list.size() == 0)
        return null;

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create((EmergencyAttendance) list.get(0));
}
项目:openmaxims-linux    文件:ObsPatientAssessmentCcImpl.java   
public ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo save(ims.emergency.vo.EmergencyAttendanceForObsPatientAssessmentVo emergencyAttForObsPatAssessmentToSave) throws ims.domain.exceptions.StaleObjectException
{
    if (emergencyAttForObsPatAssessmentToSave == null)
        throw new CodingRuntimeException("Cannot save null emergencyAttForObsPatAssessmentToSave ");
    if (!emergencyAttForObsPatAssessmentToSave.isValidated())
    {
        throw new DomainRuntimeException("emergencyAttForObsPatAssessmentToSave has not been validated");
    }

    DomainFactory factory = getDomainFactory();
    EmergencyAttendance doEmergencyAttForPatAssessment = EmergencyAttendanceForObsPatientAssessmentVoAssembler.extractEmergencyAttendance(factory, emergencyAttForObsPatAssessmentToSave);

    factory.save(doEmergencyAttForPatAssessment);

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create(doEmergencyAttForPatAssessment);
}
项目:openmaxims-linux    文件:ObsPatientAssessmentCcImpl.java   
public EmergencyAttendanceForObsPatientAssessmentVo getEmergencyAttendance(CareContextRefVo careContextRef)
{
    if (careContextRef == null || careContextRef.getID_CareContext() == null)
    {
        throw new CodingRuntimeException("Cannot get PatientAssessment on null Id for CareContext ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();
    hql.append("from EmergencyAttendance as emergAtt where emergAtt.careContext.id = :careContextID ");

    List<?> list = factory.find(hql.toString(), new String[] { "careContextID" }, new Object[] { careContextRef.getID_CareContext() });

    if (list == null || list.size() == 0)
        return null;

    return EmergencyAttendanceForObsPatientAssessmentVoAssembler.create((EmergencyAttendance) list.get(0));
}