Stream: hapi
Topic: add one resource into another resource using contained
Heerendra Singh (Oct 15 2019 at 05:19):
i am trying to add patient resource json data into coverage json,basically i am looking for a concept which will add once resource json into other resource so i found containedDt but while i am adding it using following code ,without giving error ,code is running but changes are not reflecting in output.
here i am sharing my code:-
Patient patient = new Patient();
patient.setId("patient ID");
patient.setActive(true);
coverage.getContained().getContainedResources().add(0, patient);
after this i am unable to get patient data into coverage resoponce json..
if someone can help , highly appreciated.ContainedDt
Last updated: Apr 12 2022 at 19:14 UTC