use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class TurtleTests method test_device_example_udi1.
@Test
public void test_device_example_udi1() throws FileNotFoundException, IOException, Exception {
System.out.println("device-example-udi1.ttl");
new Turtle().parse(TextFile.fileToString("C:\\work\\org.hl7.fhir\\build\\publish\\device-example-udi1.ttl"));
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeDeviceUseStatement.
protected void composeDeviceUseStatement(Complex parent, String parentType, String name, DeviceUseStatement element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeDomainResource(t, "DeviceUseStatement", name, element, index);
for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "DeviceUseStatement", "identifier", element.getIdentifier().get(i), i);
for (int i = 0; i < element.getBasedOn().size(); i++) composeReference(t, "DeviceUseStatement", "basedOn", element.getBasedOn().get(i), i);
if (element.hasStatusElement())
composeEnum(t, "DeviceUseStatement", "status", element.getStatusElement(), -1);
if (element.hasSubject())
composeReference(t, "DeviceUseStatement", "subject", element.getSubject(), -1);
for (int i = 0; i < element.getDerivedFrom().size(); i++) composeReference(t, "DeviceUseStatement", "derivedFrom", element.getDerivedFrom().get(i), i);
if (element.hasTiming())
composeType(t, "DeviceUseStatement", "timing", element.getTiming(), -1);
if (element.hasRecordedOnElement())
composeDateTime(t, "DeviceUseStatement", "recordedOn", element.getRecordedOnElement(), -1);
if (element.hasSource())
composeReference(t, "DeviceUseStatement", "source", element.getSource(), -1);
if (element.hasDevice())
composeReference(t, "DeviceUseStatement", "device", element.getDevice(), -1);
for (int i = 0; i < element.getReasonCode().size(); i++) composeCodeableConcept(t, "DeviceUseStatement", "reasonCode", element.getReasonCode().get(i), i);
for (int i = 0; i < element.getReasonReference().size(); i++) composeReference(t, "DeviceUseStatement", "reasonReference", element.getReasonReference().get(i), i);
if (element.hasBodySite())
composeCodeableConcept(t, "DeviceUseStatement", "bodySite", element.getBodySite(), -1);
for (int i = 0; i < element.getNote().size(); i++) composeAnnotation(t, "DeviceUseStatement", "note", element.getNote().get(i), i);
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeMedicinalProductPharmaceutical.
protected void composeMedicinalProductPharmaceutical(Complex parent, String parentType, String name, MedicinalProductPharmaceutical element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeDomainResource(t, "MedicinalProductPharmaceutical", name, element, index);
for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "MedicinalProductPharmaceutical", "identifier", element.getIdentifier().get(i), i);
if (element.hasAdministrableDoseForm())
composeCodeableConcept(t, "MedicinalProductPharmaceutical", "administrableDoseForm", element.getAdministrableDoseForm(), -1);
if (element.hasUnitOfPresentation())
composeCodeableConcept(t, "MedicinalProductPharmaceutical", "unitOfPresentation", element.getUnitOfPresentation(), -1);
for (int i = 0; i < element.getIngredient().size(); i++) composeReference(t, "MedicinalProductPharmaceutical", "ingredient", element.getIngredient().get(i), i);
for (int i = 0; i < element.getDevice().size(); i++) composeReference(t, "MedicinalProductPharmaceutical", "device", element.getDevice().get(i), i);
for (int i = 0; i < element.getCharacteristics().size(); i++) composeMedicinalProductPharmaceuticalMedicinalProductPharmaceuticalCharacteristicsComponent(t, "MedicinalProductPharmaceutical", "characteristics", element.getCharacteristics().get(i), i);
for (int i = 0; i < element.getRouteOfAdministration().size(); i++) composeMedicinalProductPharmaceuticalMedicinalProductPharmaceuticalRouteOfAdministrationComponent(t, "MedicinalProductPharmaceutical", "routeOfAdministration", element.getRouteOfAdministration().get(i), i);
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeDeviceDeviceSpecializationComponent.
protected void composeDeviceDeviceSpecializationComponent(Complex parent, String parentType, String name, Device.DeviceSpecializationComponent element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeBackboneElement(t, "specialization", name, element, index);
if (element.hasSystemType())
composeCodeableConcept(t, "Device", "systemType", element.getSystemType(), -1);
if (element.hasVersionElement())
composeString(t, "Device", "version", element.getVersionElement(), -1);
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeMedicationAdministration.
protected void composeMedicationAdministration(Complex parent, String parentType, String name, MedicationAdministration element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeDomainResource(t, "MedicationAdministration", name, element, index);
for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "MedicationAdministration", "identifier", element.getIdentifier().get(i), i);
for (int i = 0; i < element.getInstantiates().size(); i++) composeUri(t, "MedicationAdministration", "instantiates", element.getInstantiates().get(i), i);
for (int i = 0; i < element.getPartOf().size(); i++) composeReference(t, "MedicationAdministration", "partOf", element.getPartOf().get(i), i);
if (element.hasStatusElement())
composeEnum(t, "MedicationAdministration", "status", element.getStatusElement(), -1);
for (int i = 0; i < element.getStatusReason().size(); i++) composeCodeableConcept(t, "MedicationAdministration", "statusReason", element.getStatusReason().get(i), i);
if (element.hasCategory())
composeCodeableConcept(t, "MedicationAdministration", "category", element.getCategory(), -1);
if (element.hasMedication())
composeType(t, "MedicationAdministration", "medication", element.getMedication(), -1);
if (element.hasSubject())
composeReference(t, "MedicationAdministration", "subject", element.getSubject(), -1);
if (element.hasContext())
composeReference(t, "MedicationAdministration", "context", element.getContext(), -1);
for (int i = 0; i < element.getSupportingInformation().size(); i++) composeReference(t, "MedicationAdministration", "supportingInformation", element.getSupportingInformation().get(i), i);
if (element.hasEffective())
composeType(t, "MedicationAdministration", "effective", element.getEffective(), -1);
for (int i = 0; i < element.getPerformer().size(); i++) composeMedicationAdministrationMedicationAdministrationPerformerComponent(t, "MedicationAdministration", "performer", element.getPerformer().get(i), i);
for (int i = 0; i < element.getReasonCode().size(); i++) composeCodeableConcept(t, "MedicationAdministration", "reasonCode", element.getReasonCode().get(i), i);
for (int i = 0; i < element.getReasonReference().size(); i++) composeReference(t, "MedicationAdministration", "reasonReference", element.getReasonReference().get(i), i);
if (element.hasRequest())
composeReference(t, "MedicationAdministration", "request", element.getRequest(), -1);
for (int i = 0; i < element.getDevice().size(); i++) composeReference(t, "MedicationAdministration", "device", element.getDevice().get(i), i);
for (int i = 0; i < element.getNote().size(); i++) composeAnnotation(t, "MedicationAdministration", "note", element.getNote().get(i), i);
if (element.hasDosage())
composeMedicationAdministrationMedicationAdministrationDosageComponent(t, "MedicationAdministration", "dosage", element.getDosage(), -1);
for (int i = 0; i < element.getEventHistory().size(); i++) composeReference(t, "MedicationAdministration", "eventHistory", element.getEventHistory().get(i), i);
}
Aggregations