Skip to main content

parse_constant_from_json

Function parse_constant_from_json 

Source
pub fn parse_constant_from_json(
    c: &Value,
) -> Result<(String, ConstantValue), SofError>
Expand description

Parses a raw JSON ViewDefinition.constant[] entry into (name, value).

Used by the in-DB compiler which walks the ViewDefinition as serde_json::Value. The in-process evaluator walks typed FHIR structs instead and converts through the per-version trait impls.

Errors when name is missing or no recognised value[X] field is present.