ResourceDataRulesExecutor
This class is used to fire rules used to extract and manipulate data from FHIR resources.
NOTE: that the Facts object is not thread safe, each thread should have its own set of data to work on. When used in multi-threaded environment may exhibit unexpected behavior and return wrong results when rules are fired. Use the ResourceDataRulesExecutor in the same coroutine context of the caller.
Functions
This function computes rules based on the provided facts RepositoryResourceData.resource, RepositoryResourceData.relatedResourcesMap and RepositoryResourceData.relatedResourcesCountMap. The function returns the outcome of the computation in a map; the name of the rule is used as the key.
This function pre-computes all the Rules for ViewType's of List including list nested in the views. The LIST view computed values includes the parent's. Every list identified by ListProperties.id is added to the listResourceDataStateMap, where the value is SnapshotStateList to ensure the items are rendered (incrementally) as they are added to the list