本文整理汇总了Java中org.oscarehr.common.model.Dxresearch类的典型用法代码示例。如果您正苦于以下问题:Java Dxresearch类的具体用法?Java Dxresearch怎么用?Java Dxresearch使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Dxresearch类属于org.oscarehr.common.model包,在下文中一共展示了Dxresearch类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: populateProblem
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
private void populateProblem(VisitData visitData, Dxresearch dx) {
if(!"icd9".equals(dx.getCodingSystem())) {
return;
}
HealthProblem problem = visitData.addNewHealthProblem();
problem.setProblemDiagnosisCode(dx.getDxresearchCode());
problem.setProblemDiagnosisCodeSystem(ProblemsDiagnosisCodeSystem.ICD_9);
CodingSystemManager csm = SpringUtils.getBean(CodingSystemManager.class);
String descr = csm.getCodeDescription(dx.getCodingSystem(), dx.getDxresearchCode());
if(descr != null) {
problem.setProblemDiagnosisName(descr);
}
problem.setProblemStatus(String.valueOf(dx.getStatus()));
problem.setProblemDiagnosisDate(new XmlCalendar(dateFormatter.format(dx.getStartDate())));
/*
problem.setProblemOnsetDate(arg0);
*/
}
示例2: saveToDx
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
public void saveToDx(LoggedInInfo loggedInInfo, String demographicNo, String code, String codingSystem, boolean association) {
if (codingSystem == null) {
codingSystem = "icd10";
}
Dxresearch dx = new Dxresearch();
dx.setDxresearchCode(code);
dx.setCodingSystem(codingSystem);
dx.setDemographicNo(Integer.parseInt(demographicNo));
dx.setStartDate(new Date());
dx.setUpdateDate(new Date());
dx.setStatus('A');
dx.setAssociation(association?(byte)1:(byte)0);
dx.setProviderNo(loggedInInfo.getLoggedInProviderNo());
if (!dxresearchDAO.entryExists(dx.getDemographicNo(), codingSystem, code)) {
this.dxresearchDAO.save(dx);
}
}
示例3: addToDiseaseRegistry
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@POST
@Path("/{demographicNo}/add")
@Produces("application/json")
@Consumes("application/json")
public Response addToDiseaseRegistry(@PathParam("demographicNo") Integer demographicNo,IssueTo1 issue){
boolean activeEntryExists = dxresearchDao.activeEntryExists(demographicNo, issue.getType(), issue.getCode());
if(!activeEntryExists){
Dxresearch dx = new Dxresearch();
dx.setStartDate(new Date());
dx.setCodingSystem(issue.getType());
dx.setDemographicNo(demographicNo);
dx.setDxresearchCode(issue.getCode());
dx.setStatus('A');
dx.setProviderNo(getCurrentProvider().getProviderNo());
dxresearchDao.persist(dx);
LogAction.addLog(getLoggedInInfo(), "Dxresearch.add", "dxresearch", ""+dx.getId(), ""+demographicNo, dx.toString());
}
return Response.ok().build();
}
示例4: ProblemsModel
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
public ProblemsModel(Dxresearch problem) {
if(problem == null) {
this.problem = new Dxresearch();
} else {
this.problem = problem;
}
setIds();
setCode();
setText();
setStatusCode();
setEffectiveTime();
setValue();
setAuthor();
setSecondaryCodeICD9();
setDiagnosisDate();
}
示例5: populateClinicalStatement
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Override
public ClinicalStatement populateClinicalStatement(List<Dxresearch> problem) {
ProblemsModel problemsModel = new ProblemsModel(problem.get(0));
Observation observation = new Observation(x_ActMoodDocumentObservation.Eventoccurrence);
ArrayList<EntryRelationship> entryRelationships = new ArrayList<EntryRelationship>();
observation.setId(problemsModel.getIds());
observation.setCode(problemsModel.getCode());
observation.setText(problemsModel.getText());
observation.setStatusCode(problemsModel.getStatusCode());
observation.setEffectiveTime(problemsModel.getEffectiveTime());
observation.setValue(problemsModel.getValue());
observation.setAuthor(problemsModel.getAuthor());
entryRelationships.add(problemsModel.getSecondaryCodeICD9());
entryRelationships.add(problemsModel.getDiagnosisDate());
observation.setEntryRelationship(entryRelationships);
return observation;
}
示例6: createSummaryText
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Override
List<String> createSummaryText(PatientModel patientModel) {
List<String> summary = null;
List<Dxresearch> problems = patientModel.getProblems();
if(problems != null && !problems.isEmpty()) {
summary = problems.stream()
.filter(e -> e.getCodingSystem().equals("icd9"))
.map(e -> {
StringBuilder sb = new StringBuilder();
String description = EverestUtils.getICD9Description(e.getDxresearchCode());
if(!EverestUtils.isNullorEmptyorWhitespace(e.getDxresearchCode())) {
sb.append("ICD9: " + e.getDxresearchCode());
}
if(!EverestUtils.isNullorEmptyorWhitespace(description)) {
sb.append(" - " + description);
}
return sb.toString();
})
.collect(Collectors.toList());
}
return summary;
}
示例7: mapProblems
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
private void mapProblems(ArrayList<Component3> components) {
if(original == Original.SOURCE) {
List<Dxresearch> problems = model.getProblems();
if(problems != null && !problems.isEmpty()) {
problems.forEach(problem -> rules.add(new ProblemsRule(problem, null)));
}
} else if(original == Original.TARGET) {
Component3 component = findBodySection(components, Problems.getConstants());
if(component != null) {
ArrayList<Entry> entries = component.getSection().getEntry();
if(entries != null && !entries.isEmpty()) {
entries.forEach(entry -> rules.add(new ProblemsRule(null, entry)));
}
}
}
}
示例8: reduceProblems
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
private void reduceProblems(ArrayList<Component3> components) {
if(original == Original.SOURCE) {
Component3 component = findBodySection(components, Problems.getConstants());
if(component != null) {
results.entrySet().forEach(e -> {
if(e.getKey().startsWith(ProblemsRule.class.getSimpleName())) {
component.getSection().getEntry().add((Entry) e.getValue().getRight());
}
});
}
} else if(original == Original.TARGET) {
results.entrySet().forEach(e -> {
if(e.getKey().startsWith(ProblemsRule.class.getSimpleName())) {
model.getProblems().add((Dxresearch) e.getValue().getLeft());
}
});
}
}
示例9: problemsLensGetTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsLensGetTest() {
ProblemsLens lens = new ProblemsLens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.get(blankPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
assertEquals(x_ActRelationshipEntry.DRIV, pair.getRight().getTypeCode().getCode());
assertTrue(pair.getRight().getContextConductionInd().getValue());
assertTrue(pair.getRight().getTemplateId().contains(new II(bodyConstants.ENTRY_TEMPLATE_ID)));
Observation observation = pair.getRight().getClinicalStatementIfObservation();
assertNotNull(observation);
assertEquals(x_ActMoodDocumentObservation.Eventoccurrence, observation.getMoodCode().getCode());
assertNotNull(observation.getEntryRelationship());
}
示例10: problemsIdLensGetTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsIdLensGetTest() {
ProblemsIdLens lens = new ProblemsIdLens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.get(getPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
SET<II> id = pair.getRight().getClinicalStatementIfObservation().getId();
assertNotNull(id);
assertEquals(Constants.EMR.EMR_OID, id.get(0).getRoot());
assertTrue(id.get(0).getExtension().startsWith(Constants.IdPrefixes.ProblemList.toString()));
assertTrue(id.get(0).getExtension().endsWith(problem.getDxresearchNo().toString()));
}
示例11: problemsStatusCodeLensGetTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsStatusCodeLensGetTest() {
ProblemsStatusCodeLens lens = new ProblemsStatusCodeLens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.get(getPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
CS<ActStatus> statusCode = pair.getRight().getClinicalStatementIfObservation().getStatusCode();
assertNotNull(statusCode);
assertEquals(ActStatus.Active, statusCode.getCode());
statusCode = null;
getPair = Pair.of(new Dxresearch(), getPair.getRight());
getPair.getLeft().setStatus('C');
getPair.getRight().getClinicalStatementIfObservation().setStatusCode(statusCode);
pair = lens.get(getPair);
statusCode = pair.getRight().getClinicalStatementIfObservation().getStatusCode();
assertEquals(ActStatus.Completed, statusCode.getCode());
}
示例12: problemsStatusCodeLensPutTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsStatusCodeLensPutTest() {
ProblemsStatusCodeLens lens = new ProblemsStatusCodeLens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.put(putPair, putPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
assertTrue(pair.getLeft().getStatus().equals('D'));
putPair = Pair.of(new Dxresearch(), putPair.getRight());
putPair.getRight().getClinicalStatementIfObservation().setStatusCode(ActStatus.Active);
pair = lens.put(putPair, putPair);
assertTrue(pair.getLeft().getStatus().equals('A'));
putPair = Pair.of(new Dxresearch(), putPair.getRight());
putPair.getRight().getClinicalStatementIfObservation().setStatusCode(ActStatus.Completed);
pair = lens.put(putPair, putPair);
assertTrue(pair.getLeft().getStatus().equals('C'));
}
示例13: problemsEffectiveTimeLensGetTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsEffectiveTimeLensGetTest() {
ProblemsEffectiveTimeLens lens = new ProblemsEffectiveTimeLens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.get(getPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
IVL<TS> effectiveTime = pair.getRight().getClinicalStatementIfObservation().getEffectiveTime();
assertNotNull(effectiveTime);
assertFalse(effectiveTime.isNull());
assertFalse(effectiveTime.getLow().isNull());
assertFalse(effectiveTime.getLow().isInvalidDate());
assertEquals(new TSDateLens().get(problem.getStartDate()), effectiveTime.getLow());
}
示例14: problemsICD9LensGetTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@SuppressWarnings("unchecked")
@Test
public void problemsICD9LensGetTest() {
ProblemsICD9Lens lens = new ProblemsICD9Lens();
assertNotNull(lens);
Pair<Dxresearch, Entry> pair = lens.get(getPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
ArrayList<EntryRelationship> entryRelationships = pair.getRight().getClinicalStatementIfObservation().getEntryRelationship();
EntryRelationship entryRelationship = EverestUtils.findEntryRelationship(entryRelationships, Constants.ObservationOids.SECONDARY_CODE_ICD9_OBSERVATION_TEMPLATE_ID);
assertNotNull(entryRelationship);
assertEquals(CD.class, entryRelationship.getClinicalStatementIfObservation().getValue().getClass());
CD<String> value = (CD<String>) entryRelationship.getClinicalStatementIfObservation().getValue();
assertEquals(Constants.CodeSystems.ICD9_OID, value.getCodeSystem());
assertEquals(problem.getDxresearchCode(), value.getCode());
}
示例15: problemsICD9LensPutTest
import org.oscarehr.common.model.Dxresearch; //导入依赖的package包/类
@Test
public void problemsICD9LensPutTest() {
ProblemsICD9Lens lens = new ProblemsICD9Lens();
assertNotNull(lens);
EntryRelationship entryRelationship = EverestUtils.createObservationTemplate(Constants.ObservationOids.SECONDARY_CODE_ICD9_OBSERVATION_TEMPLATE_ID);
entryRelationship.getClinicalStatementIfObservation().setValue(new CD<>(problem.getDxresearchCode(), Constants.CodeSystems.ICD9_OID));
putPair.getRight().getClinicalStatementIfObservation().getEntryRelationship().add(entryRelationship);
Pair<Dxresearch, Entry> pair = lens.put(putPair, putPair);
assertNotNull(pair);
assertNotNull(pair.getLeft());
assertNotNull(pair.getRight());
assertEquals(problem.getDxresearchCode(), pair.getLeft().getDxresearchCode());
assertEquals("icd9", pair.getLeft().getCodingSystem());
}