Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prefer getId() as data source API for getting string-based ids
The CQL execution engine requires that data models expose an id over the API and it expects that this id is a string. Currently this is only used when building out the results object (in which the patient id is used as a key) -- but it is important. Problems arise when a data model defines an id property that is not a string. This is the case for the FHIR data models (in which id is an object, in order to support extensions). Then the required string-based id conflicts with the data-model defined object id. To get around this, we change the API to expect a getId() function that should return the ID as a string. To support backwards compatibility (i.e., not break Bonnie and other apps), if the getId() function isn't found, we fall back to id().
- Loading branch information