Add Evaluate Library operation and bump CR (#5570)
* add evaluateLibrary operation * add tests and constants for operations * move off snapshot * code review comments * version bump to 6.11.8-SNAPSHOT * spotless edit
This commit is contained in:
parent
644c68872f
commit
b5c028f80a
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-bom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<packaging>pom</packaging>
|
||||
<name>HAPI FHIR BOM</name>
|
||||
|
@ -12,7 +12,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-cli</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
type: add
|
||||
issue: 5569
|
||||
title: "Upgrade Clinical Reasoning version for latest bug fixes and available operations. Add $evaluate library operation."
|
|
@ -11,7 +11,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -104,13 +104,16 @@ public class ProviderConstants {
|
|||
public static final String OPERATION_MDM_SUBMIT_OUT_PARAM_SUBMITTED = "submitted";
|
||||
public static final String MDM_BATCH_RUN_CRITERIA = "criteria";
|
||||
public static final String MDM_BATCH_RUN_RESOURCE_TYPE = "resourceType";
|
||||
/**
|
||||
* CQL Operations
|
||||
*/
|
||||
public static final String CQL_EVALUATE_MEASURE = "$evaluate-measure";
|
||||
|
||||
/**
|
||||
* Clinical Reasoning Operations
|
||||
*/
|
||||
public static final String CR_OPERATION_EVALUATE_MEASURE = "$evaluate-measure";
|
||||
|
||||
public static final String CR_OPERATION_CARE_GAPS = "$care-gaps";
|
||||
public static final String CR_OPERATION_SUBMIT_DATA = "$submit-data";
|
||||
public static final String CR_OPERATION_EVALUATE = "$evaluate";
|
||||
public static final String CR_OPERATION_CQL = "$cql";
|
||||
public static final String CR_OPERATION_APPLY = "$apply";
|
||||
|
||||
public static final String CR_OPERATION_R5_APPLY = "$r5.apply";
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<artifactId>hapi-fhir-serviceloaders</artifactId>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<artifactId>hapi-fhir-serviceloaders</artifactId>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
@ -21,7 +21,7 @@
|
|||
<dependency>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-caching-api</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<artifactId>hapi-fhir-serviceloaders</artifactId>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-spring-boot-samples</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>hapi-fhir-spring-boot-sample-client-apache</artifactId>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-spring-boot-samples</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-spring-boot-samples</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir-spring-boot</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
</parent>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -27,15 +27,18 @@ import ca.uhn.fhir.cr.config.ProviderSelector;
|
|||
import ca.uhn.fhir.cr.config.RepositoryConfig;
|
||||
import ca.uhn.fhir.cr.r4.ICareGapsServiceFactory;
|
||||
import ca.uhn.fhir.cr.r4.ICqlExecutionServiceFactory;
|
||||
import ca.uhn.fhir.cr.r4.ILibraryEvaluationServiceFactory;
|
||||
import ca.uhn.fhir.cr.r4.IMeasureServiceFactory;
|
||||
import ca.uhn.fhir.cr.r4.ISubmitDataProcessorFactory;
|
||||
import ca.uhn.fhir.cr.r4.cqlexecution.CqlExecutionOperationProvider;
|
||||
import ca.uhn.fhir.cr.r4.cpg.CqlExecutionOperationProvider;
|
||||
import ca.uhn.fhir.cr.r4.cpg.LibraryEvaluationOperationProvider;
|
||||
import ca.uhn.fhir.cr.r4.measure.CareGapsOperationProvider;
|
||||
import ca.uhn.fhir.cr.r4.measure.MeasureOperationsProvider;
|
||||
import ca.uhn.fhir.cr.r4.measure.SubmitDataProvider;
|
||||
import ca.uhn.fhir.rest.server.RestfulServer;
|
||||
import org.opencds.cqf.fhir.cql.EvaluationSettings;
|
||||
import org.opencds.cqf.fhir.cr.cql.r4.R4CqlExecutionService;
|
||||
import org.opencds.cqf.fhir.cr.cpg.r4.R4CqlExecutionService;
|
||||
import org.opencds.cqf.fhir.cr.cpg.r4.R4LibraryEvaluationService;
|
||||
import org.opencds.cqf.fhir.cr.measure.CareGapsProperties;
|
||||
import org.opencds.cqf.fhir.cr.measure.MeasureEvaluationOptions;
|
||||
import org.opencds.cqf.fhir.cr.measure.r4.R4CareGapsService;
|
||||
|
@ -72,11 +75,22 @@ public class CrR4Config {
|
|||
return rd -> new R4CqlExecutionService(theRepositoryFactory.create(rd), theEvaluationSettings);
|
||||
}
|
||||
|
||||
@Bean
|
||||
ILibraryEvaluationServiceFactory r4LibraryEvaluationServiceFactory(
|
||||
IRepositoryFactory theRepositoryFactory, EvaluationSettings theEvaluationSettings) {
|
||||
return rd -> new R4LibraryEvaluationService(theRepositoryFactory.create(rd), theEvaluationSettings);
|
||||
}
|
||||
|
||||
@Bean
|
||||
CqlExecutionOperationProvider r4CqlExecutionOperationProvider() {
|
||||
return new CqlExecutionOperationProvider();
|
||||
}
|
||||
|
||||
@Bean
|
||||
LibraryEvaluationOperationProvider r4LibraryEvaluationOperationProvider() {
|
||||
return new LibraryEvaluationOperationProvider();
|
||||
}
|
||||
|
||||
@Bean
|
||||
ICareGapsServiceFactory careGapsServiceFactory(
|
||||
IRepositoryFactory theRepositoryFactory,
|
||||
|
@ -118,7 +132,8 @@ public class CrR4Config {
|
|||
MeasureOperationsProvider.class,
|
||||
SubmitDataProvider.class,
|
||||
CareGapsOperationProvider.class,
|
||||
CqlExecutionOperationProvider.class)));
|
||||
CqlExecutionOperationProvider.class,
|
||||
LibraryEvaluationOperationProvider.class)));
|
||||
|
||||
return new ProviderLoader(theRestfulServer, theApplicationContext, selector);
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ public class MeasureOperationsProvider {
|
|||
* autopopulated HAPI.
|
||||
* @return the calculated MeasureReport
|
||||
*/
|
||||
@Operation(name = ProviderConstants.CQL_EVALUATE_MEASURE, idempotent = true, type = Measure.class)
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_EVALUATE_MEASURE, idempotent = true, type = Measure.class)
|
||||
public MeasureReport evaluateMeasure(
|
||||
@IdParam IdType theId,
|
||||
@OperationParam(name = "periodStart") String thePeriodStart,
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
package ca.uhn.fhir.cr.r4;
|
||||
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import org.opencds.cqf.fhir.cr.cql.r4.R4CqlExecutionService;
|
||||
import org.opencds.cqf.fhir.cr.cpg.r4.R4CqlExecutionService;
|
||||
|
||||
@FunctionalInterface
|
||||
public interface ICqlExecutionServiceFactory {
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
package ca.uhn.fhir.cr.r4;
|
||||
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import org.opencds.cqf.fhir.cr.cpg.r4.R4LibraryEvaluationService;
|
||||
|
||||
@FunctionalInterface
|
||||
public interface ILibraryEvaluationServiceFactory {
|
||||
R4LibraryEvaluationService create(RequestDetails theRequestDetails);
|
||||
}
|
|
@ -17,13 +17,14 @@
|
|||
* limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package ca.uhn.fhir.cr.r4.cqlexecution;
|
||||
package ca.uhn.fhir.cr.r4.cpg;
|
||||
|
||||
import ca.uhn.fhir.cr.r4.ICqlExecutionServiceFactory;
|
||||
import ca.uhn.fhir.model.api.annotation.Description;
|
||||
import ca.uhn.fhir.rest.annotation.Operation;
|
||||
import ca.uhn.fhir.rest.annotation.OperationParam;
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.r4.model.BooleanType;
|
||||
import org.hl7.fhir.r4.model.Bundle;
|
||||
import org.hl7.fhir.r4.model.Endpoint;
|
||||
|
@ -112,7 +113,7 @@ public class CqlExecutionOperationProvider {
|
|||
* is a CQL system-defined or FHIR-defined type, the result is returned
|
||||
* as a {@link Parameters} Parameters resource
|
||||
*/
|
||||
@Operation(name = "$cql")
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_CQL)
|
||||
@Description(
|
||||
shortDefinition = "$cql",
|
||||
value =
|
|
@ -0,0 +1,107 @@
|
|||
package ca.uhn.fhir.cr.r4.cpg;
|
||||
|
||||
import ca.uhn.fhir.cr.r4.ILibraryEvaluationServiceFactory;
|
||||
import ca.uhn.fhir.rest.annotation.IdParam;
|
||||
import ca.uhn.fhir.rest.annotation.Operation;
|
||||
import ca.uhn.fhir.rest.annotation.OperationParam;
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.r4.model.Bundle;
|
||||
import org.hl7.fhir.r4.model.Endpoint;
|
||||
import org.hl7.fhir.r4.model.IdType;
|
||||
import org.hl7.fhir.r4.model.Library;
|
||||
import org.hl7.fhir.r4.model.Parameters;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class LibraryEvaluationOperationProvider {
|
||||
@Autowired
|
||||
ILibraryEvaluationServiceFactory myLibraryEvaluationServiceFactory;
|
||||
/**
|
||||
* Evaluates a CQL library and returns the results as a Parameters resource.
|
||||
*
|
||||
* @param theRequestDetails the {@link RequestDetails RequestDetails}
|
||||
* @param theId the library resource's Id
|
||||
* @param theSubject Subject for which the library will be evaluated.
|
||||
* This corresponds to the context in which the
|
||||
* library
|
||||
* will be evaluated and is represented as a relative
|
||||
* FHIR id (e.g. Patient/123), which establishes both
|
||||
* the context and context value for the evaluation
|
||||
* @param theExpression Expression(s) to be evaluated. If no expression
|
||||
* names
|
||||
* are provided, the operation evaluates all public
|
||||
* expression definitions in the library
|
||||
* @param theParameters Any input parameters for the expression.
|
||||
* {@link Parameters} Parameters defined in this
|
||||
* input will be made available by name to the CQL
|
||||
* expression. Parameter types are mapped to CQL as
|
||||
* specified in the Using CQL section of the CPG
|
||||
* Implementation guide. If a parameter appears more
|
||||
* than once in the input Parameters resource, it is
|
||||
* represented with a List in the input CQL. If a
|
||||
* parameter has parts, it is represented as a Tuple
|
||||
* in the input CQL
|
||||
* @param theData Data to be made available to the library
|
||||
* evaluation. This parameter is exclusive with the
|
||||
* prefetchData parameter (i.e. either provide all
|
||||
* data as a single bundle, or provide data using
|
||||
* multiple bundles with prefetch descriptions)
|
||||
* @param thePrefetchData ***Not Yet Implemented***
|
||||
* @param theDataEndpoint An {@link Endpoint} endpoint to use to access data
|
||||
* referenced by retrieve operations in the library.
|
||||
* If provided, this endpoint is used after the data
|
||||
* or prefetchData bundles, and the server, if the
|
||||
* useServerData parameter is true.
|
||||
* @param theContentEndpoint An {@link Endpoint} endpoint to use to access
|
||||
* content (i.e. libraries) referenced by the
|
||||
* library. If no content endpoint is supplied, the
|
||||
* evaluation will attempt to retrieve content from
|
||||
* the server on which the operation is being
|
||||
* performed
|
||||
* @param theTerminologyEndpoint An {@link Endpoint} endpoint to use to access
|
||||
* terminology (i.e. valuesets, codesystems, and
|
||||
* membership testing) referenced by the library. If
|
||||
* no terminology endpoint is supplied, the
|
||||
* evaluation will attempt to use the server on which
|
||||
* the operation is being performed as the
|
||||
* terminology server
|
||||
* @return The results of the library evaluation, returned as a
|
||||
* {@link Parameters} resource
|
||||
* with a parameter for each named expression defined in the library.
|
||||
* The value of
|
||||
* each expression is returned as a FHIR type, either a resource, or a
|
||||
* FHIR-defined
|
||||
* type corresponding to the CQL return type, as defined in the Using
|
||||
* CQL section of
|
||||
* this implementation guide. If the result of an expression is a list
|
||||
* of resources,
|
||||
* that parameter will be repeated for each element in the result
|
||||
*/
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_EVALUATE, idempotent = true, type = Library.class)
|
||||
public Parameters evaluate(
|
||||
RequestDetails theRequestDetails,
|
||||
@IdParam IdType theId,
|
||||
@OperationParam(name = "subject") String theSubject,
|
||||
@OperationParam(name = "expression") List<String> theExpression,
|
||||
@OperationParam(name = "parameters") Parameters theParameters,
|
||||
@OperationParam(name = "data") Bundle theData,
|
||||
@OperationParam(name = "prefetchData") List<Parameters> thePrefetchData,
|
||||
@OperationParam(name = "dataEndpoint") Endpoint theDataEndpoint,
|
||||
@OperationParam(name = "contentEndpoint") Endpoint theContentEndpoint,
|
||||
@OperationParam(name = "terminologyEndpoint") Endpoint theTerminologyEndpoint) {
|
||||
return myLibraryEvaluationServiceFactory
|
||||
.create(theRequestDetails)
|
||||
.evaluate(
|
||||
theId,
|
||||
theSubject,
|
||||
theExpression,
|
||||
theParameters,
|
||||
theData,
|
||||
thePrefetchData,
|
||||
theDataEndpoint,
|
||||
theContentEndpoint,
|
||||
theTerminologyEndpoint);
|
||||
}
|
||||
}
|
|
@ -25,6 +25,7 @@ import ca.uhn.fhir.model.api.annotation.Description;
|
|||
import ca.uhn.fhir.rest.annotation.Operation;
|
||||
import ca.uhn.fhir.rest.annotation.OperationParam;
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.instance.model.api.IPrimitiveType;
|
||||
import org.hl7.fhir.r4.model.CanonicalType;
|
||||
import org.hl7.fhir.r4.model.Measure;
|
||||
|
@ -97,7 +98,7 @@ public class CareGapsOperationProvider {
|
|||
shortDefinition = "$care-gaps operation",
|
||||
value =
|
||||
"Implements the <a href=\"http://build.fhir.org/ig/HL7/davinci-deqm/OperationDefinition-care-gaps.html\">$care-gaps</a> operation found in the <a href=\"http://build.fhir.org/ig/HL7/davinci-deqm/index.html\">Da Vinci DEQM FHIR Implementation Guide</a> which is an extension of the <a href=\"http://build.fhir.org/operation-measure-care-gaps.html\">$care-gaps</a> operation found in the <a href=\"http://hl7.org/fhir/R4/clinicalreasoning-module.html\">FHIR Clinical Reasoning Module</a>.")
|
||||
@Operation(name = "$care-gaps", idempotent = true, type = Measure.class)
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_CARE_GAPS, idempotent = true, type = Measure.class)
|
||||
public Parameters careGapsReport(
|
||||
RequestDetails theRequestDetails,
|
||||
@OperationParam(name = "periodStart", typeName = "date") IPrimitiveType<Date> thePeriodStart,
|
||||
|
|
|
@ -63,7 +63,7 @@ public class MeasureOperationsProvider {
|
|||
* autopopulated HAPI.
|
||||
* @return the calculated MeasureReport
|
||||
*/
|
||||
@Operation(name = ProviderConstants.CQL_EVALUATE_MEASURE, idempotent = true, type = Measure.class)
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_EVALUATE_MEASURE, idempotent = true, type = Measure.class)
|
||||
public MeasureReport evaluateMeasure(
|
||||
@IdParam IdType theId,
|
||||
@OperationParam(name = "periodStart") String thePeriodStart,
|
||||
|
|
|
@ -25,6 +25,7 @@ import ca.uhn.fhir.rest.annotation.IdParam;
|
|||
import ca.uhn.fhir.rest.annotation.Operation;
|
||||
import ca.uhn.fhir.rest.annotation.OperationParam;
|
||||
import ca.uhn.fhir.rest.api.server.RequestDetails;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.instance.model.api.IBaseResource;
|
||||
import org.hl7.fhir.r4.model.Bundle;
|
||||
import org.hl7.fhir.r4.model.IdType;
|
||||
|
@ -70,7 +71,7 @@ public class SubmitDataProvider {
|
|||
shortDefinition = "$submit-data",
|
||||
value =
|
||||
"Implements the <a href=\"http://hl7.org/fhir/R4/measure-operation-submit-data.html\">$submit-data</a> operation found in the <a href=\"http://hl7.org/fhir/R4/clinicalreasoning-module.html\">FHIR Clinical Reasoning Module</a> per the <a href=\"http://build.fhir.org/ig/HL7/davinci-deqm/datax.html#submit-data\">Da Vinci DEQM FHIR Implementation Guide</a>.")
|
||||
@Operation(name = "$submit-data", type = Measure.class)
|
||||
@Operation(name = ProviderConstants.CR_OPERATION_SUBMIT_DATA, type = Measure.class)
|
||||
public Bundle submitData(
|
||||
RequestDetails theRequestDetails,
|
||||
@IdParam IdType theId,
|
||||
|
|
|
@ -2,6 +2,7 @@ package ca.uhn.fhir.cr.dstu3;
|
|||
|
||||
|
||||
import ca.uhn.fhir.cr.dstu3.measure.MeasureOperationsProvider;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hamcrest.Matchers;
|
||||
import org.hl7.fhir.dstu3.model.Bundle;
|
||||
import org.hl7.fhir.dstu3.model.DateType;
|
||||
|
@ -82,7 +83,7 @@ public class CrDstu3MeasureOperationProviderIT extends BaseCrDstu3TestServer {
|
|||
}
|
||||
|
||||
return ourClient.operation().onInstance(measureId)
|
||||
.named("$evaluate-measure")
|
||||
.named(ProviderConstants.CR_OPERATION_EVALUATE_MEASURE)
|
||||
.withParameters(parametersEval1)
|
||||
.returnResourceType(MeasureReport.class)
|
||||
.execute();
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package ca.uhn.fhir.cr.r4;
|
||||
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.r4.model.Bundle;
|
||||
import org.hl7.fhir.r4.model.CodeableConcept;
|
||||
import org.hl7.fhir.r4.model.Coding;
|
||||
|
@ -69,7 +70,7 @@ class CareGapsProviderIT extends BaseCrR4TestServer
|
|||
parameters.addParameter("measureId", "ColorectalCancerScreeningsFHIR");
|
||||
|
||||
var result = ourClient.operation().onType(Measure.class)
|
||||
.named("$care-gaps")
|
||||
.named(ProviderConstants.CR_OPERATION_CARE_GAPS)
|
||||
.withParameters(parameters)
|
||||
.returnResourceType(Parameters.class)
|
||||
.execute();
|
||||
|
@ -84,7 +85,7 @@ class CareGapsProviderIT extends BaseCrR4TestServer
|
|||
|
||||
// 7. Provider runs care-gaps again
|
||||
result = ourClient.operation().onType("Measure")
|
||||
.named("care-gaps")
|
||||
.named(ProviderConstants.CR_OPERATION_CARE_GAPS)
|
||||
.withParameters(parameters)
|
||||
.execute();
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package ca.uhn.fhir.cr.r4;
|
||||
|
||||
|
||||
import ca.uhn.fhir.cr.r4.cqlexecution.CqlExecutionOperationProvider;
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.r4.model.BooleanType;
|
||||
import org.hl7.fhir.r4.model.Bundle;
|
||||
import org.hl7.fhir.r4.model.Condition;
|
||||
|
@ -12,12 +12,11 @@ import org.hl7.fhir.r4.model.OperationOutcome;
|
|||
import org.hl7.fhir.r4.model.Parameters;
|
||||
import org.hl7.fhir.r4.model.Patient;
|
||||
import org.hl7.fhir.r4.model.Period;
|
||||
import org.hl7.fhir.r4.model.StringType;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||
import static org.opencds.cqf.fhir.utility.r4.Parameters.booleanPart;
|
||||
import static org.opencds.cqf.fhir.utility.r4.Parameters.canonicalPart;
|
||||
import static org.opencds.cqf.fhir.utility.r4.Parameters.parameters;
|
||||
|
@ -28,43 +27,66 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
|
|||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
|
||||
public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
||||
@Autowired
|
||||
CqlExecutionOperationProvider myCqlExecutionProvider;
|
||||
public class CpgOperationProviderTest extends BaseCrR4TestServer{
|
||||
@BeforeEach
|
||||
void setup() throws IOException {
|
||||
void setup() {
|
||||
var reqDeets = setupRequestDetails();
|
||||
loadResource(Library.class, "SimpleR4Library.json", reqDeets);
|
||||
loadResource(Patient.class, "SimplePatient.json", reqDeets);
|
||||
loadResource(Observation.class, "SimpleObservation.json", reqDeets);
|
||||
loadResource(Condition.class, "SimpleCondition.json", reqDeets);
|
||||
}
|
||||
public Parameters runCqlExecution(Parameters parameters){
|
||||
|
||||
var results = ourClient.operation().onServer()
|
||||
.named("$cql")
|
||||
.withParameters(parameters)
|
||||
.execute();
|
||||
return results;
|
||||
}
|
||||
@Test
|
||||
void testSimpleDateCqlExecutionProvider() {
|
||||
void cqlExecutionProvider_testSimpleDate() {
|
||||
// execute cql expression on date interval
|
||||
Parameters params = parameters(stringPart("expression", "Interval[Today() - 2 years, Today())"));
|
||||
Parameters results = runCqlExecution(params);
|
||||
assertTrue(results.getParameter("return").getValue() instanceof Period);
|
||||
}
|
||||
|
||||
@Test
|
||||
void testSimpleArithmeticCqlExecutionProvider() {
|
||||
void cqlExecutionProvider_testSimpleArithmetic() {
|
||||
// execute simple cql expression
|
||||
Parameters params = parameters(stringPart("expression", "5 * 5"));
|
||||
Parameters results = runCqlExecution(params);
|
||||
assertTrue(results.getParameter("return").getValue() instanceof IntegerType);
|
||||
assertEquals("25", ((IntegerType) results.getParameter("return").getValue()).asStringValue());
|
||||
}
|
||||
@Test
|
||||
void testReferencedLibraryCqlExecutionProvider() {
|
||||
|
||||
var test = ourClient.read().resource(Library.class).withId("SimpleR4Library").execute();
|
||||
@Test
|
||||
void evaluateLibraryProvider_testLibraryWithSubject() {
|
||||
// evaluate library resource for a subject
|
||||
var params = new Parameters();
|
||||
params.addParameter("subject", new StringType("Patient/SimplePatient"));
|
||||
|
||||
Parameters report = runEvaluateLibrary(params, "SimpleR4Library");
|
||||
|
||||
assertNotNull(report);
|
||||
assertTrue(report.hasParameter("Initial Population"));
|
||||
assertTrue(((BooleanType) report.getParameter("Initial Population").getValue()).booleanValue());
|
||||
assertTrue(report.hasParameter("Numerator"));
|
||||
assertTrue(((BooleanType) report.getParameter("Numerator").getValue()).booleanValue());
|
||||
assertTrue(report.hasParameter("Denominator"));
|
||||
assertTrue(((BooleanType) report.getParameter("Denominator").getValue()).booleanValue());
|
||||
}
|
||||
|
||||
@Test
|
||||
void evaluateLibraryProvider_testSimpleExpression() {
|
||||
// evaluate expression for subject from specified library resource
|
||||
var params = new Parameters();
|
||||
params.addParameter("subject", new StringType("Patient/SimplePatient"));
|
||||
params.addParameter("expression", "Numerator");
|
||||
|
||||
Parameters report = runEvaluateLibrary(params, "SimpleR4Library");
|
||||
assertNotNull(report);
|
||||
assertTrue(report.hasParameter("Numerator"));
|
||||
assertTrue(((BooleanType) report.getParameter("Numerator").getValue()).booleanValue());
|
||||
}
|
||||
|
||||
@Test
|
||||
void cqlExecutionProvider_testReferencedLibrary() {
|
||||
// execute cql expression from referenced library on subject
|
||||
Parameters libraryParameter = parameters(
|
||||
canonicalPart("url", ourClient.getServerBase() + "/Library/SimpleR4Library|0.0.1"),
|
||||
stringPart("name", "SimpleR4Library"));
|
||||
|
@ -79,9 +101,10 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
}
|
||||
|
||||
@Test
|
||||
void testDataBundleCqlExecutionProvider() throws IOException {
|
||||
void cqlExecutionProvider_testDataBundle() {
|
||||
// execute cql expression from library over data from bundle with no subject
|
||||
Parameters libraryParameter = parameters(
|
||||
canonicalPart("url", this.ourClient.getServerBase() + "/Library/SimpleR4Library"),
|
||||
canonicalPart("url", ourClient.getServerBase() + "/Library/SimpleR4Library"),
|
||||
stringPart("name", "SimpleR4Library"));
|
||||
//var data = loadBundle(Bundle.class,"SimpleDataBundle.json");
|
||||
var data = (Bundle) readResource("SimpleDataBundle.json");
|
||||
|
@ -96,7 +119,8 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
}
|
||||
|
||||
@Test
|
||||
void testDataBundleCqlExecutionProviderWithSubject() {
|
||||
void cqlExecutionProvider_testDataBundleWithSubject() {
|
||||
// execute cql expression from library over data from bundle with subject
|
||||
Parameters libraryParameter = parameters(
|
||||
canonicalPart("url", ourClient.getServerBase() + "/Library/SimpleR4Library"),
|
||||
stringPart("name", "SimpleR4Library"));
|
||||
|
@ -112,7 +136,8 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
}
|
||||
|
||||
@Test
|
||||
void testSimpleParametersCqlExecutionProvider() {
|
||||
void cqlExecutionProvider_testSimpleParameters() {
|
||||
// execute inline cql date expression with input valuemv
|
||||
Parameters evaluationParams = parameters(
|
||||
datePart("%inputDate", "2019-11-01"));
|
||||
Parameters params = parameters(
|
||||
|
@ -124,7 +149,8 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
}
|
||||
|
||||
@Test
|
||||
void testCqlExecutionProviderExpression() {
|
||||
void cqlExecutionProvider_testExpression() {
|
||||
// execute cql expression from referenced library
|
||||
Parameters libraryParameter = parameters(
|
||||
canonicalPart("url", ourClient.getServerBase() + "/Library/SimpleR4Library"),
|
||||
stringPart("name", "SimpleR4Library"));
|
||||
|
@ -143,9 +169,12 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
}
|
||||
|
||||
@Test
|
||||
void testErrorExpression() {
|
||||
void cqlExecutionProvider_testErrorExpression() {
|
||||
// execute invalid cql expression
|
||||
Parameters params = parameters(stringPart("expression", "Interval[1,5]"));
|
||||
|
||||
Parameters results = runCqlExecution(params);
|
||||
|
||||
assertTrue(results.hasParameter());
|
||||
assertTrue(results.getParameterFirstRep().hasName());
|
||||
assertEquals("evaluation error", results.getParameterFirstRep().getName());
|
||||
|
@ -155,4 +184,19 @@ public class CqlExecutionOperationProviderTest extends BaseCrR4TestServer{
|
|||
((OperationOutcome) results.getParameterFirstRep().getResource()).getIssueFirstRep().getDetails()
|
||||
.getText());
|
||||
}
|
||||
|
||||
public Parameters runCqlExecution(Parameters parameters){
|
||||
|
||||
return ourClient.operation().onServer()
|
||||
.named(ProviderConstants.CR_OPERATION_CQL)
|
||||
.withParameters(parameters)
|
||||
.execute();
|
||||
}
|
||||
public Parameters runEvaluateLibrary(Parameters parameters, String libraryId){
|
||||
|
||||
return ourClient.operation().onInstance("Library/" + libraryId)
|
||||
.named(ProviderConstants.CR_OPERATION_EVALUATE)
|
||||
.withParameters(parameters)
|
||||
.execute();
|
||||
}
|
||||
}
|
|
@ -1,5 +1,6 @@
|
|||
package ca.uhn.fhir.cr.r4;
|
||||
|
||||
import ca.uhn.fhir.rest.server.provider.ProviderConstants;
|
||||
import org.hl7.fhir.r4.model.DateType;
|
||||
import org.hl7.fhir.r4.model.IdType;
|
||||
import org.hl7.fhir.r4.model.MeasureReport;
|
||||
|
@ -11,6 +12,7 @@ import org.junit.jupiter.api.extension.ExtendWith;
|
|||
|
||||
import org.springframework.test.context.junit.jupiter.SpringExtension;
|
||||
|
||||
import java.util.NoSuchElementException;
|
||||
import java.util.Optional;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
@ -30,7 +32,7 @@ class R4MeasureOperationProviderIT extends BaseCrR4TestServer {
|
|||
parametersEval.addParameter("subject", subject);
|
||||
|
||||
var report = ourClient.operation().onInstance("Measure/" + measureId)
|
||||
.named("$evaluate-measure")
|
||||
.named(ProviderConstants.CR_OPERATION_EVALUATE_MEASURE)
|
||||
.withParameters(parametersEval)
|
||||
.returnResourceType(MeasureReport.class)
|
||||
.execute();
|
||||
|
@ -41,7 +43,7 @@ class R4MeasureOperationProviderIT extends BaseCrR4TestServer {
|
|||
}
|
||||
|
||||
@Test
|
||||
void testMeasureEvaluate_EXM130() throws InterruptedException {
|
||||
void testMeasureEvaluate_EXM130() {
|
||||
loadBundle("ColorectalCancerScreeningsFHIR-bundle.json");
|
||||
runEvaluateMeasure("2019-01-01", "2019-12-31", "Patient/numer-EXM130", "ColorectalCancerScreeningsFHIR", "Individual", null);
|
||||
}
|
||||
|
@ -59,22 +61,13 @@ class R4MeasureOperationProviderIT extends BaseCrR4TestServer {
|
|||
var returnMeasureReport = runEvaluateMeasure("2022-01-01", "2022-12-31", patientId, measureId, "Individual", null);
|
||||
|
||||
for (MeasureReport.MeasureReportGroupPopulationComponent population : returnMeasureReport.getGroupFirstRep()
|
||||
.getPopulation()) {
|
||||
switch (population.getCode().getCodingFirstRep().getCode()) {
|
||||
case "initial-population":
|
||||
assertEquals(initialPopulationCount, population.getCount());
|
||||
break;
|
||||
case "denominator":
|
||||
assertEquals(denominatorCount, population.getCount());
|
||||
break;
|
||||
case "denominator-exclusion":
|
||||
assertEquals(denominatorExclusionCount, population.getCount());
|
||||
break;
|
||||
case "numerator":
|
||||
assertEquals(numeratorCount, population.getCount());
|
||||
break;
|
||||
}
|
||||
}
|
||||
.getPopulation())
|
||||
switch (population.getCode().getCodingFirstRep().getCode()) {
|
||||
case "initial-population" -> assertEquals(initialPopulationCount, population.getCount());
|
||||
case "denominator" -> assertEquals(denominatorCount, population.getCount());
|
||||
case "denominator-exclusion" -> assertEquals(denominatorExclusionCount, population.getCount());
|
||||
case "numerator" -> assertEquals(numeratorCount, population.getCount());
|
||||
}
|
||||
|
||||
Observation enrolledDuringParticipationPeriodObs = null;
|
||||
Observation participationPeriodObs = null;
|
||||
|
@ -148,7 +141,7 @@ class R4MeasureOperationProviderIT extends BaseCrR4TestServer {
|
|||
}
|
||||
|
||||
@Test
|
||||
void testLargeValuesetMeasure() {
|
||||
void testLargeValuesetMeasure() throws NoSuchElementException {
|
||||
this.loadBundle("largeValueSetMeasureTest-Bundle.json");
|
||||
|
||||
var returnMeasureReport = runEvaluateMeasure("2023-01-01", "2024-01-01", null, "CMSTest", "population", null);
|
||||
|
@ -160,10 +153,12 @@ class R4MeasureOperationProviderIT extends BaseCrR4TestServer {
|
|||
.getPopulation().stream().filter(x -> x.hasCode() && x.getCode().hasCoding()
|
||||
&& x.getCode().getCoding().get(0).getCode().equals(populationName))
|
||||
.findFirst();
|
||||
|
||||
assertEquals(population.get().getCount(), expectedCount,
|
||||
String.format("expected count for population \"%s\" did not match", populationName));
|
||||
|
||||
assertTrue(population.isPresent(), String.format("population \"%s\" not found in report", populationName));
|
||||
assertEquals(
|
||||
expectedCount,
|
||||
population.get().getCount(),
|
||||
String.format("expected count for population \"%s\" did not match", populationName)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -19,8 +19,6 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||
|
||||
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||
public class SubmitDataServiceR4Test extends BaseCrR4TestServer {
|
||||
@Autowired
|
||||
IRepositoryFactory myRepositoryFactory;
|
||||
|
||||
@Autowired
|
||||
ISubmitDataProcessorFactory myR4SubmitDataProcessorFactory;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-deployable-pom</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../hapi-deployable-pom/pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
4
pom.xml
4
pom.xml
|
@ -9,7 +9,7 @@
|
|||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<name>HAPI-FHIR</name>
|
||||
<description>An open-source implementation of the FHIR specification in Java.</description>
|
||||
|
@ -992,7 +992,7 @@
|
|||
<ucum_version>1.0.8</ucum_version>
|
||||
|
||||
<!-- CQL Support -->
|
||||
<clinical-reasoning.version>3.0.0-PRE12</clinical-reasoning.version>
|
||||
<clinical-reasoning.version>3.0.0-PRE14</clinical-reasoning.version>
|
||||
|
||||
<!-- Site properties -->
|
||||
<fontawesomeVersion>5.4.1</fontawesomeVersion>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>ca.uhn.hapi.fhir</groupId>
|
||||
<artifactId>hapi-fhir</artifactId>
|
||||
<version>6.11.7-SNAPSHOT</version>
|
||||
<version>6.11.8-SNAPSHOT</version>
|
||||
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
|
Loading…
Reference in New Issue