Add additionalContext and error
This commit is contained in:
parent
6a0efdfe0b
commit
c28a100f02
|
@ -1,6 +1,7 @@
|
||||||
package org.hl7.fhir.convertors.conv43_50.resources43_50;
|
package org.hl7.fhir.convertors.conv43_50.resources43_50;
|
||||||
|
|
||||||
import org.hl7.fhir.convertors.context.ConversionContext43_50;
|
import org.hl7.fhir.convertors.context.ConversionContext43_50;
|
||||||
|
import org.hl7.fhir.convertors.conv43_50.datatypes43_50.general43_50.CodeableConcept43_50;
|
||||||
import org.hl7.fhir.convertors.conv43_50.datatypes43_50.primitive43_50.Canonical43_50;
|
import org.hl7.fhir.convertors.conv43_50.datatypes43_50.primitive43_50.Canonical43_50;
|
||||||
|
|
||||||
import org.hl7.fhir.convertors.conv43_50.datatypes43_50.primitive43_50.Instant43_50;
|
import org.hl7.fhir.convertors.conv43_50.datatypes43_50.primitive43_50.Instant43_50;
|
||||||
|
@ -39,6 +40,11 @@ public class SubscriptionStatus43_50 {
|
||||||
if (src.hasTopic()) {
|
if (src.hasTopic()) {
|
||||||
tgt.setTopicElement(Canonical43_50.convertCanonical(src.getTopicElement()));
|
tgt.setTopicElement(Canonical43_50.convertCanonical(src.getTopicElement()));
|
||||||
}
|
}
|
||||||
|
if (src.hasError()) {
|
||||||
|
for (org.hl7.fhir.r5.model.CodeableConcept srcError : src.getError()) {
|
||||||
|
tgt.addError(CodeableConcept43_50.convertCodeableConcept(srcError));
|
||||||
|
}
|
||||||
|
}
|
||||||
return tgt;
|
return tgt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -53,6 +59,11 @@ public class SubscriptionStatus43_50 {
|
||||||
if (src.hasFocus()) {
|
if (src.hasFocus()) {
|
||||||
tgt.setFocus(Reference43_50.convertReference(src.getFocus()));
|
tgt.setFocus(Reference43_50.convertReference(src.getFocus()));
|
||||||
}
|
}
|
||||||
|
if (src.hasAdditionalContext()) {
|
||||||
|
for (org.hl7.fhir.r5.model.Reference ref : src.getAdditionalContext()) {
|
||||||
|
tgt.addAdditionalContext(Reference43_50.convertReference(ref));
|
||||||
|
}
|
||||||
|
}
|
||||||
return tgt;
|
return tgt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -113,6 +124,11 @@ public class SubscriptionStatus43_50 {
|
||||||
if (src.hasTopic()) {
|
if (src.hasTopic()) {
|
||||||
tgt.setTopicElement(Canonical43_50.convertCanonical(src.getTopicElement()));
|
tgt.setTopicElement(Canonical43_50.convertCanonical(src.getTopicElement()));
|
||||||
}
|
}
|
||||||
|
if (src.hasError()) {
|
||||||
|
for (org.hl7.fhir.r4b.model.CodeableConcept srcError : src.getError()) {
|
||||||
|
tgt.addError(CodeableConcept43_50.convertCodeableConcept(srcError));
|
||||||
|
}
|
||||||
|
}
|
||||||
return tgt;
|
return tgt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -127,6 +143,11 @@ public class SubscriptionStatus43_50 {
|
||||||
if (src.hasFocus()) {
|
if (src.hasFocus()) {
|
||||||
tgt.setFocus(Reference43_50.convertReference(src.getFocus()));
|
tgt.setFocus(Reference43_50.convertReference(src.getFocus()));
|
||||||
}
|
}
|
||||||
|
if (src.hasAdditionalContext()) {
|
||||||
|
for (org.hl7.fhir.r4b.model.Reference ref : src.getAdditionalContext()) {
|
||||||
|
tgt.addAdditionalContext(Reference43_50.convertReference(ref));
|
||||||
|
}
|
||||||
|
}
|
||||||
return tgt;
|
return tgt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -10,10 +10,27 @@
|
||||||
"eventsSinceSubscriptionStart" : "1000",
|
"eventsSinceSubscriptionStart" : "1000",
|
||||||
"notificationEvent" : [{
|
"notificationEvent" : [{
|
||||||
"eventNumber" : "1000",
|
"eventNumber" : "1000",
|
||||||
"timestamp" : "2022-02-10T15:12:28-05:00"
|
"timestamp" : "2022-02-10T15:12:28-05:00",
|
||||||
|
"additionalContext": [
|
||||||
|
{
|
||||||
|
"reference": "http://example.org/FHIR/R5/Patient/ABC"
|
||||||
|
}
|
||||||
|
]
|
||||||
}],
|
}],
|
||||||
"subscription" : {
|
"subscription" : {
|
||||||
"reference" : "http://example.org/FHIR/R5/Subscription/123"
|
"reference" : "http://example.org/FHIR/R5/Subscription/123"
|
||||||
},
|
},
|
||||||
"topic" : "http://example.org/FHIR/R5/SubscriptionTopic/admission"
|
"topic" : "http://example.org/FHIR/R5/SubscriptionTopic/admission",
|
||||||
|
"error": [
|
||||||
|
{
|
||||||
|
"code": {
|
||||||
|
"coding": [
|
||||||
|
{
|
||||||
|
"code": "no-response ",
|
||||||
|
"system": "http://terminology.hl7.org/CodeSystem/subscription-error"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
Loading…
Reference in New Issue