Tools to validate a prescription before attempting to fill it. Pharmacist will make the best the situation, and in the case of cyclic dependencies and other forms of invalid states, it will just stop processing. The functions in this namespace can help you trigger those situations as errors instead.
Tools to validate a prescription before attempting to fill it. Pharmacist will make the best the situation, and in the case of cyclic dependencies and other forms of invalid states, it will just stop processing. The functions in this namespace can help you trigger those situations as errors instead.
(find-cyclic-dep prescription path)
Find the cyclic dependency from path
in prescription
, if any. If a
cyclic dependency is found, the function will return a vector indicating the
full path, otherwise it returns nil.
Find the cyclic dependency from `path` in `prescription`, if any. If a cyclic dependency is found, the function will return a vector indicating the full path, otherwise it returns nil.
(validate-deps prescription & [params])
Validate the dependencies in prescription
, and ensure that every dependency
can be met. Optionally provide initial parameters as params
. Returns a map
of {:type :data :message}
in case of problems, where :type
is one of
:cyclic-dependency
, :missing-dep
, or :source-shadowing
, :message
is a
human readable explanation of the problem, and :data
provides details about
the problem.
Validate the dependencies in `prescription`, and ensure that every dependency can be met. Optionally provide initial parameters as `params`. Returns a map of `{:type :data :message}` in case of problems, where `:type` is one of `:cyclic-dependency`, `:missing-dep`, or `:source-shadowing`, `:message` is a human readable explanation of the problem, and `:data` provides details about the problem.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close