add convenience function for turning bundles into sequences of resources
This commit is contained in:
parent
46ea41807e
commit
eb88fbca20
|
@ -93,6 +93,13 @@
|
||||||
(format-search-value value))]))
|
(format-search-value value))]))
|
||||||
(apply concat)))
|
(apply concat)))
|
||||||
|
|
||||||
|
(defn collect-resources
|
||||||
|
"returns a sequence containing all of the resources contained in the given bundle"
|
||||||
|
[bundle]
|
||||||
|
(->> bundle
|
||||||
|
:entry
|
||||||
|
(map :content)))
|
||||||
|
|
||||||
(defn get-resource
|
(defn get-resource
|
||||||
"gets a single resource from a FHIR server. can optionally get a specific version of a resource.
|
"gets a single resource from a FHIR server. can optionally get a specific version of a resource.
|
||||||
|
|
||||||
|
|
Reference in a new issue