Merge pull request #137 from hapifhir/grahame_work
fix convertors for ConceptMap and remove debugging statement
This commit is contained in:
commit
d7757195cb
|
@ -134,14 +134,19 @@ public class ConceptMap10_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.dstu2.model.Enumerations.ConceptMapEquivalence.EQUIVALENT);
|
||||
break;
|
||||
case BROADER:
|
||||
tgt.setValue(org.hl7.fhir.dstu2.model.Enumerations.ConceptMapEquivalence.WIDER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.dstu2.model.Enumerations.ConceptMapEquivalence.NARROWER);
|
||||
break;
|
||||
case NOTRELATEDTO:
|
||||
tgt.setValue(org.hl7.fhir.dstu2.model.Enumerations.ConceptMapEquivalence.DISJOINT);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.dstu2.model.Enumerations.ConceptMapEquivalence.NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return tgt;
|
||||
|
@ -157,24 +162,34 @@ public class ConceptMap10_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case EQUAL:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case WIDER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case SUBSUMES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case SPECIALIZES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case INEXACT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.RELATEDTO);
|
||||
break;
|
||||
case UNMATCHED:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
case DISJOINT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NOTRELATEDTO);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
}
|
||||
return tgt;
|
||||
}
|
||||
|
|
|
@ -142,14 +142,19 @@ public class ConceptMap14_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.dstu2016may.model.Enumerations.ConceptMapEquivalence.EQUIVALENT);
|
||||
break;
|
||||
case BROADER:
|
||||
tgt.setValue(org.hl7.fhir.dstu2016may.model.Enumerations.ConceptMapEquivalence.WIDER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.dstu2016may.model.Enumerations.ConceptMapEquivalence.NARROWER);
|
||||
break;
|
||||
case NOTRELATEDTO:
|
||||
tgt.setValue(org.hl7.fhir.dstu2016may.model.Enumerations.ConceptMapEquivalence.DISJOINT);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.dstu2016may.model.Enumerations.ConceptMapEquivalence.NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return tgt;
|
||||
|
@ -165,24 +170,34 @@ public class ConceptMap14_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case EQUAL:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case WIDER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case SUBSUMES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case SPECIALIZES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case INEXACT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.RELATEDTO);
|
||||
break;
|
||||
case UNMATCHED:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
case DISJOINT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NOTRELATEDTO);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
}
|
||||
return tgt;
|
||||
}
|
||||
|
|
|
@ -206,14 +206,19 @@ public class ConceptMap30_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.dstu3.model.Enumerations.ConceptMapEquivalence.EQUIVALENT);
|
||||
break;
|
||||
case BROADER:
|
||||
tgt.setValue(org.hl7.fhir.dstu3.model.Enumerations.ConceptMapEquivalence.WIDER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.dstu3.model.Enumerations.ConceptMapEquivalence.NARROWER);
|
||||
break;
|
||||
case NOTRELATEDTO:
|
||||
tgt.setValue(org.hl7.fhir.dstu3.model.Enumerations.ConceptMapEquivalence.DISJOINT);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.dstu3.model.Enumerations.ConceptMapEquivalence.NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return tgt;
|
||||
|
@ -229,24 +234,34 @@ public class ConceptMap30_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case EQUAL:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case WIDER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case SUBSUMES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case SPECIALIZES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case INEXACT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.RELATEDTO);
|
||||
break;
|
||||
case UNMATCHED:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
case DISJOINT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NOTRELATEDTO);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
}
|
||||
return tgt;
|
||||
}
|
||||
|
|
|
@ -258,14 +258,19 @@ public class ConceptMap40_50 extends VersionConvertor_40_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.r4.model.Enumerations.ConceptMapEquivalence.EQUIVALENT);
|
||||
break;
|
||||
case BROADER:
|
||||
tgt.setValue(org.hl7.fhir.r4.model.Enumerations.ConceptMapEquivalence.WIDER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.r4.model.Enumerations.ConceptMapEquivalence.NARROWER);
|
||||
break;
|
||||
case NOTRELATEDTO:
|
||||
tgt.setValue(org.hl7.fhir.r4.model.Enumerations.ConceptMapEquivalence.DISJOINT);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.r4.model.Enumerations.ConceptMapEquivalence.NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return tgt;
|
||||
|
@ -281,24 +286,34 @@ public class ConceptMap40_50 extends VersionConvertor_40_50 {
|
|||
switch(src.getValue()) {
|
||||
case EQUIVALENT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case EQUAL:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.EQUIVALENT);
|
||||
break;
|
||||
case WIDER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case SUBSUMES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.BROADER);
|
||||
break;
|
||||
case NARROWER:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case SPECIALIZES:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NARROWER);
|
||||
break;
|
||||
case INEXACT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.RELATEDTO);
|
||||
break;
|
||||
case UNMATCHED:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
case DISJOINT:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NOTRELATEDTO);
|
||||
break;
|
||||
default:
|
||||
tgt.setValue(org.hl7.fhir.r5.model.Enumerations.ConceptMapRelationship.NULL);
|
||||
break;
|
||||
}
|
||||
return tgt;
|
||||
}
|
||||
|
|
|
@ -4831,7 +4831,6 @@ public class NarrativeGenerator implements INarrativeGenerator {
|
|||
}
|
||||
|
||||
public XhtmlNode renderBundle(Bundle b) throws FHIRException {
|
||||
System.out.println("render "+b.getId());
|
||||
if (b.getType() == BundleType.DOCUMENT) {
|
||||
if (!b.hasEntry() || !(b.getEntryFirstRep().hasResource() && b.getEntryFirstRep().getResource() instanceof Composition))
|
||||
throw new FHIRException("Invalid document - first entry is not a Composition");
|
||||
|
|
Loading…
Reference in New Issue