use of org.hl7.fhir.r4.model.ActivityDefinition in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeActivityDefinitionActivityDefinitionDynamicValueComponent.
protected void composeActivityDefinitionActivityDefinitionDynamicValueComponent(Complex parent, String parentType, String name, ActivityDefinition.ActivityDefinitionDynamicValueComponent element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeBackboneElement(t, "dynamicValue", name, element, index);
if (element.hasPathElement())
composeString(t, "ActivityDefinition", "path", element.getPathElement(), -1);
if (element.hasExpression())
composeExpression(t, "ActivityDefinition", "expression", element.getExpression(), -1);
}
use of org.hl7.fhir.r4.model.ActivityDefinition in project org.hl7.fhir.core by hapifhir.
the class RdfParser method composeActivityDefinitionActivityDefinitionParticipantComponent.
protected void composeActivityDefinitionActivityDefinitionParticipantComponent(Complex parent, String parentType, String name, ActivityDefinition.ActivityDefinitionParticipantComponent element, int index) {
if (element == null)
return;
Complex t;
if (Utilities.noString(parentType))
t = parent;
else {
t = parent.predicate("fhir:" + parentType + '.' + name);
}
composeBackboneElement(t, "participant", name, element, index);
if (element.hasTypeElement())
composeEnum(t, "ActivityDefinition", "type", element.getTypeElement(), -1);
if (element.hasRole())
composeCodeableConcept(t, "ActivityDefinition", "role", element.getRole(), -1);
}
use of org.hl7.fhir.r4.model.ActivityDefinition in project org.hl7.fhir.core by hapifhir.
the class JsonParserTest method testComposeAndParseWithOriginal.
@Test
void testComposeAndParseWithOriginal() throws FHIRFormatError, IOException {
JsonParser jsonParser = new JsonParser();
Resource resource = jsonParser.parse(TestingUtilities.loadTestResourceStream("r3", "activitydefinition-referralprimarycarementalhealth-original.json"));
String composed = jsonParser.composeString(resource);
jsonParser.parse(composed);
}
use of org.hl7.fhir.r4.model.ActivityDefinition in project org.hl7.fhir.core by hapifhir.
the class DataRenderer method isCanonical.
private boolean isCanonical(String path) {
if (!path.endsWith(".url"))
return false;
String t = path.substring(0, path.length() - 4);
StructureDefinition sd = getContext().getWorker().fetchTypeDefinition(t);
if (sd == null)
return false;
if (Utilities.existsInList(t, VersionUtilities.getCanonicalResourceNames(getContext().getWorker().getVersion()))) {
return true;
}
if (Utilities.existsInList(t, "ActivityDefinition", "CapabilityStatement", "CapabilityStatement2", "ChargeItemDefinition", "Citation", "CodeSystem", "CompartmentDefinition", "ConceptMap", "ConditionDefinition", "EventDefinition", "Evidence", "EvidenceReport", "EvidenceVariable", "ExampleScenario", "GraphDefinition", "ImplementationGuide", "Library", "Measure", "MessageDefinition", "NamingSystem", "PlanDefinition"))
return true;
return sd.getBaseDefinitionElement().hasExtension("http://hl7.org/fhir/StructureDefinition/structuredefinition-codegen-super");
}
Aggregations