Tri-state capability profile: pure construction and queries.
A capability absent from the profile is :unknown. Nothing in this namespace turns :unknown into :yes or :no; only evidence does, and every verdict keeps the ids of the evidence that produced it.
Tri-state capability profile: pure construction and queries. A capability absent from the profile is :unknown. Nothing in this namespace turns :unknown into :yes or :no; only evidence does, and every verdict keeps the ids of the evidence that produced it.
(add-evidence profile {:keys [id cap verdict] :as ev})Record capability evidence and fold its verdict into the cap entry.
Record capability evidence and fold its verdict into the cap entry.
(admits? profile requires)True only when every required capability is proven :yes.
True only when every required capability is proven :yes.
(classify profile requires)Partition a requires-set by verdict. Each group is sorted.
Partition a requires-set by verdict. Each group is sorted.
(declare-cap profile cap verdict reason)Declare a verdict for cap by policy rather than by probe.
Declare a verdict for cap by policy rather than by probe.
(declare-text profile k v reason)Declare a text constraint on generated programs: :max-len (UTF-8 bytes) or :forbid (a set of substrings that must not appear).
Declare a text constraint on generated programs: :max-len (UTF-8 bytes) or :forbid (a set of substrings that must not appear).
(evidence-for profile caps)Evidence ids behind the given capabilities, in capability order.
Evidence ids behind the given capabilities, in capability order.
(not-refuted? profile requires)True when no required capability is :no. Unknowns pass. Used only to say what resolving the unknowns would unlock, never to select a program.
True when no required capability is :no. Unknowns pass. Used only to say what resolving the unknowns would unlock, never to select a program.
(verdict profile cap)The verdict for cap: :yes, :no or :unknown (never nil).
The verdict for cap: :yes, :no or :unknown (never nil).
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |