(->out m)
Converts a map into something you can use for assertions. Basically takes every keyword at the root that doesn't have a question mark at the end and adds a question mark to it.
Converts a map into something you can use for assertions. Basically takes every keyword at the root that doesn't have a question mark at the end and adds a question mark to it.
(-h->k ks)
(assert-cell r n expected actual)
(assert-value expected actual)
(assert-value current-state expected actual)
(balance-row desired-length row)
(bdt current-state args {:keys [rows] :as t})
(cell-value current-state v)
(decision-table args {:keys [rows] :as t} process-row-fn)
(defparser n f)
(deftfn n args & body)
Define a table processing function or helper. The structure of the args
differs depending on the contexts in which it is intended to be used.
If you give args
as a map instead of a vector, then your function is assumed
to take a single map. You can describe how that map's values get coerced upon
invocation by declaring a [symbol fn]
pair inside a vector bound to :in
.
The keyword form of the symbol
is the key into the given map whereby its
value can be retrieved. The fn
will be invoked on that value, and its result
bound to the given symbol. If you don't want a coercion to occur, simply
put the symbol
into the vector directly.
Another thing you can do with this map-based table function declaration is
declare a series of output coercions. All table functions must return
a map, so you can specify how the values in those maps are converted to
Strings. By default, we will invoke str
on any non-string, non-nil values.
However, you can force the issue with a map associated to :out
which
specifies which function to invoke on each value mapped to the given key.
If a function is given, regardless of whether there is even a value present
in the resultant map, that function will be invoked. If there is no value
present, then that function will be invoked on nil
.
Note that, if your function returns something other than a map, (for example,
the table table fixture requires the result to be a vector of maps), the
:out
keyword is simply ignored.
You can see a complete example of this macro in action in the
itl.example.bank
namespace.
Otherwise, args
should be a vector and all the normal defn
things apply.
Define a table processing function or helper. The structure of the `args` differs depending on the contexts in which it is intended to be used. If you give `args` as a map instead of a vector, then your function is assumed to take a single map. You can describe how that map's values get coerced upon invocation by declaring a `[symbol fn]` pair inside a vector bound to `:in`. The keyword form of the `symbol` is the key into the given map whereby its value can be retrieved. The `fn` will be invoked on that value, and its result bound to the given symbol. If you don't want a coercion to occur, simply put the `symbol` into the vector directly. Another thing you can do with this map-based table function declaration is declare a series of output coercions. All table functions must return a map, so you can specify how the values in those maps are converted to Strings. By default, we will invoke `str` on any non-string, non-nil values. However, you can force the issue with a map associated to `:out` which specifies which function to invoke on each value mapped to the given key. If a function is given, regardless of whether there is even a value present in the resultant map, that function will be invoked. If there is no value present, then that function will be invoked on `nil`. Note that, if your function returns something other than a map, (for example, the table table fixture requires the result to be a vector of maps), the `:out` keyword is simply ignored. You can see a complete example of this macro in action in the `itl.example.bank` namespace. Otherwise, `args` should be a vector and all the normal `defn` things apply.
(dt current-state args t)
(exec-file indir outdir file)
Run a file on the classpath through the asciidoc parser/generator
Run a file on the classpath through the asciidoc parser/generator
(execute execute-fn status-fn initial-state in out)
Parse a document on in
that contains bindings, assertions, and/or
operations, executing them, and writing the modified markdown into the given
out
. The initial-state
is a map of bindings that the document can use.
Parse a document on `in` that contains bindings, assertions, and/or operations, executing them, and writing the modified markdown into the given `out`. The `initial-state` is a map of bindings that the document can use.
(execute-function current-state common-params expected f-name f args out-name)
(execute-pages current-state
{:strs [indir outdir] :as args}
{:keys [rows] :as t})
(function current-state args {:keys [raw-rows] :as t})
(handle-execute-page-row indir
outdir
{:strs [File Pass Fail Result Exception] :as r})
(handle-function-row common-params
{:keys [current-state max-length] :as reduction}
[expected & rest-of-row])
(parse-bool s__11069__auto__)
(parse-date s__11069__auto__)
(parse-date* s)
(parse-double s__11069__auto__)
(parse-float s__11069__auto__)
(parse-int s__11069__auto__)
(parse-long s__11069__auto__)
(parse-short s__11069__auto__)
(parse-uuid s__11069__auto__)
(printable v)
(process-decision-row current-state f f-args row)
(process-query-row [expected-row actual-row])
(query current-state args {:keys [rows] :as t})
(remove-nil-values m)
(resolve-values current-state m & [key-fn])
(run file)
(run file out-file)
Execute file
. If out-file
is specified, results will be written there.
Otherwise they will be written to file
replacing the extension with
.html
. AKA: README.md -> README.html
Execute `file`. If `out-file` is specified, results will be written there. Otherwise they will be written to `file` replacing the extension with `.html`. AKA: `README.md -> README.html`
(stringify-values stringifiers m)
Given a map m
, cause all its non-nil values to become strings. If any
given key also is present in stringifers
, then invoke the function
referred to by that key on the value instead. That function must also
emit a string.
If m
is not a map, it is simply returned untouched.
Given a map `m`, cause all its non-nil values to become strings. If any given key also is present in `stringifers`, then invoke the function referred to by that key on the value instead. That function must also emit a string. If `m` is not a map, it is simply returned untouched.
(table current-state args {:keys [raw-rows]})
(usens current-state _ {:keys [rows] :as t})
(with-helper-fn args b & body)
(with-max-threads n & body)
(with-max-threads* n f)
(with-parallel-support args b & body)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close