firely-net-sdk
firely-net-sdk copied to clipboard
Add environment variables to FhirPath
At this moment, it is possible to add constants to the SymbolTable so you can supply your own external values (just like functions) and refer to them from FhirPath.
However, it is also really useful to supply extrernal variables that can be different from invocation to invocation of a compiled fhirpath statement, variables that are specific for a single run of an expression.
We already pass in an EvaluationContext
when we run an expression, so a natural extension point would be to make it possible to add context variables here, that can then be referenced from the FhirPath, e.g. with the normal %
Alternatively, we could introduce our own syntax in FhirPath, but that requires changes to the parser and brings little added value.