use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeMedia.
protected void composeMedia(Complex parent, String parentType, String name, Media element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeDomainResource(t, "Media", name, element, index);
for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "Media", "identifier", element.getIdentifier().get(i), i);
for (int i = 0; i < element.getBasedOn().size(); i++) composeReference(t, "Media", "basedOn", element.getBasedOn().get(i), i);
if (element.hasTypeElement())
composeEnum(t, "Media", "type", element.getTypeElement(), -1);
if (element.hasSubtype())
composeCodeableConcept(t, "Media", "subtype", element.getSubtype(), -1);
if (element.hasView())
composeCodeableConcept(t, "Media", "view", element.getView(), -1);
if (element.hasSubject())
composeReference(t, "Media", "subject", element.getSubject(), -1);
if (element.hasContext())
composeReference(t, "Media", "context", element.getContext(), -1);
if (element.hasOccurrence())
composeType(t, "Media", "occurrence", element.getOccurrence(), -1);
if (element.hasOperator())
composeReference(t, "Media", "operator", element.getOperator(), -1);
for (int i = 0; i < element.getReasonCode().size(); i++) composeCodeableConcept(t, "Media", "reasonCode", element.getReasonCode().get(i), i);
if (element.hasBodySite())
composeCodeableConcept(t, "Media", "bodySite", element.getBodySite(), -1);
if (element.hasDevice())
composeReference(t, "Media", "device", element.getDevice(), -1);
if (element.hasHeightElement())
composePositiveInt(t, "Media", "height", element.getHeightElement(), -1);
if (element.hasWidthElement())
composePositiveInt(t, "Media", "width", element.getWidthElement(), -1);
if (element.hasFramesElement())
composePositiveInt(t, "Media", "frames", element.getFramesElement(), -1);
if (element.hasDurationElement())
composeUnsignedInt(t, "Media", "duration", element.getDurationElement(), -1);
if (element.hasContent())
composeAttachment(t, "Media", "content", element.getContent(), -1);
for (int i = 0; i < element.getNote().size(); i++) composeAnnotation(t, "Media", "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 composeDeviceDeviceUdiComponent.
protected void composeDeviceDeviceUdiComponent(Complex parent, String parentType, String name, Device.DeviceUdiComponent element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeBackboneElement(t, "udi", name, element, index);
if (element.hasDeviceIdentifierElement())
composeString(t, "Device", "deviceIdentifier", element.getDeviceIdentifierElement(), -1);
if (element.hasNameElement())
composeString(t, "Device", "name", element.getNameElement(), -1);
if (element.hasJurisdictionElement())
composeUri(t, "Device", "jurisdiction", element.getJurisdictionElement(), -1);
if (element.hasCarrierHRFElement())
composeString(t, "Device", "carrierHRF", element.getCarrierHRFElement(), -1);
if (element.hasCarrierAIDCElement())
composeBase64Binary(t, "Device", "carrierAIDC", element.getCarrierAIDCElement(), -1);
if (element.hasIssuerElement())
composeUri(t, "Device", "issuer", element.getIssuerElement(), -1);
if (element.hasEntryTypeElement())
composeEnum(t, "Device", "entryType", element.getEntryTypeElement(), -1);
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeMolecularSequence.
protected void composeMolecularSequence(Complex parent, String parentType, String name, MolecularSequence element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeDomainResource(t, "MolecularSequence", name, element, index);
for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "MolecularSequence", "identifier", element.getIdentifier().get(i), i);
if (element.hasTypeElement())
composeEnum(t, "MolecularSequence", "type", element.getTypeElement(), -1);
if (element.hasCoordinateSystemElement())
composeInteger(t, "MolecularSequence", "coordinateSystem", element.getCoordinateSystemElement(), -1);
if (element.hasPatient())
composeReference(t, "MolecularSequence", "patient", element.getPatient(), -1);
if (element.hasSpecimen())
composeReference(t, "MolecularSequence", "specimen", element.getSpecimen(), -1);
if (element.hasDevice())
composeReference(t, "MolecularSequence", "device", element.getDevice(), -1);
if (element.hasPerformer())
composeReference(t, "MolecularSequence", "performer", element.getPerformer(), -1);
if (element.hasQuantity())
composeQuantity(t, "MolecularSequence", "quantity", element.getQuantity(), -1);
if (element.hasReferenceSeq())
composeMolecularSequenceMolecularSequenceReferenceSeqComponent(t, "MolecularSequence", "referenceSeq", element.getReferenceSeq(), -1);
for (int i = 0; i < element.getVariant().size(); i++) composeMolecularSequenceMolecularSequenceVariantComponent(t, "MolecularSequence", "variant", element.getVariant().get(i), i);
if (element.hasObservedSeqElement())
composeString(t, "MolecularSequence", "observedSeq", element.getObservedSeqElement(), -1);
for (int i = 0; i < element.getQuality().size(); i++) composeMolecularSequenceMolecularSequenceQualityComponent(t, "MolecularSequence", "quality", element.getQuality().get(i), i);
if (element.hasReadCoverageElement())
composeInteger(t, "MolecularSequence", "readCoverage", element.getReadCoverageElement(), -1);
for (int i = 0; i < element.getRepository().size(); i++) composeMolecularSequenceMolecularSequenceRepositoryComponent(t, "MolecularSequence", "repository", element.getRepository().get(i), i);
for (int i = 0; i < element.getPointer().size(); i++) composeReference(t, "MolecularSequence", "pointer", element.getPointer().get(i), i);
for (int i = 0; i < element.getStructureVariant().size(); i++) composeMolecularSequenceMolecularSequenceStructureVariantComponent(t, "MolecularSequence", "structureVariant", element.getStructureVariant().get(i), i);
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class TurtleTests method test_device_example.
@Test
public void test_device_example() throws FileNotFoundException, IOException, Exception {
System.out.println("device-example.ttl");
new Turtle().parse(TextFile.fileToString("C:\\work\\org.hl7.fhir\\build\\publish\\device-example.ttl"));
}
use of org.hl7.fhir.dstu3.model.Device in project org.hl7.fhir.core by hapifhir.
the class TurtleTests method test_device_example_software.
@Test
public void test_device_example_software() throws FileNotFoundException, IOException, Exception {
System.out.println("device-example-software.ttl");
new Turtle().parse(TextFile.fileToString("C:\\work\\org.hl7.fhir\\build\\publish\\device-example-software.ttl"));
}
Aggregations