use of org.hl7.fhir.convertors.advisors.impl.BaseAdvisor_30_50 in project cqf-ruler by DBCG.
the class DataRequirements method getModuleDefinitionLibraryDstu3.
public static org.hl7.fhir.dstu3.model.Library getModuleDefinitionLibraryDstu3(LibraryManager libraryManager, TranslatedLibrary translatedLibrary, CqlTranslatorOptions options) {
org.hl7.fhir.r5.model.Library libraryR5 = getModuleDefinitionLibraryR5(libraryManager, translatedLibrary, options);
BaseAdvisor_30_50 baseAdvisor_30_50 = new BaseAdvisor_30_50();
VersionConvertor_30_50 versionConvertor_30_50 = new VersionConvertor_30_50(baseAdvisor_30_50);
org.hl7.fhir.dstu3.model.Library libraryDstu3 = null;
libraryDstu3 = (org.hl7.fhir.dstu3.model.Library) versionConvertor_30_50.convertResource(libraryR5);
// There is no DSTU3 extension to support FHIRQueryPattern representation on a DataRequirement
return libraryDstu3;
}
use of org.hl7.fhir.convertors.advisors.impl.BaseAdvisor_30_50 in project cqf-ruler by DBCG.
the class DataRequirements method getModuleDefinitionLibraryDstu3.
public static org.hl7.fhir.dstu3.model.Library getModuleDefinitionLibraryDstu3(org.hl7.fhir.dstu3.model.Measure measureToUse, LibraryManager libraryManager, TranslatedLibrary translatedLibrary, CqlTranslatorOptions options) {
VersionConvertor_30_50 versionConvertor_30_50 = new VersionConvertor_30_50(new BaseAdvisor_30_50());
org.hl7.fhir.r5.model.Measure r5Measure = (org.hl7.fhir.r5.model.Measure) versionConvertor_30_50.convertResource(measureToUse);
Set<String> expressionList = getExpressions(r5Measure);
DataRequirementsProcessor dqReqTrans = new DataRequirementsProcessor();
org.hl7.fhir.r5.model.Library effectiveDataRequirements = dqReqTrans.gatherDataRequirements(libraryManager, translatedLibrary, options, expressionList, true);
org.hl7.fhir.dstu3.model.Library stu3EffectiveDataRequirements = (org.hl7.fhir.dstu3.model.Library) versionConvertor_30_50.convertResource(effectiveDataRequirements);
// TODO: Support dataRequirementFhirQueries in STU3
return stu3EffectiveDataRequirements;
}
Aggregations