Tags

Ns

Symbols

zen
{
tag
{
:zen/tags
#{
:zen/desc
"register resource as a tag"
set
{
:confirms
:zen/tags
:typemap
ctx
{
:zen/tags
:typemap
:zen/desc
"schema for context"
:keys
{
:tags
{
:typeset
:every
{
:typesymbol
:symbols
{
:typemap
map
{
:zen/tags
:typemap
:keys
{
:key
{
:confirms
:zen/desc
"Validate keys against schema. Turn off unknown-keys validation"
:require
{
:typeset
:zen/desc
"Set of required keys; set means 'one of key' is required."
:every
{
:typecase
:case
[
[0]
{
:when
{
:typekeyword
[1]
{
:when
{
:typeset
:zen/desc
"mean 'one of this keys'"
:every
{
:typekeyword
:keys
{
:typemap
:values
{
:confirms
:typemap
:keys
{
:type
{
:typesymbol
:values
{
:confirms
:exclusive-keys
{
:typeset
:zen/desc
"Set of exclusive groups; each group"
:every
{
:typeset
:minItems
2
:every
{
:typecase
:case
[
[0]
{
:when
{
:typekeyword
[1]
{
:when
{
:typeset
:then
{
:typeset
:every
{
:typekeyword
:schema-key
{
:require
#{
:key
:typemap
:keys
{
:key
{
:typekeyword
:ns
{
:typestring
:zen/desc
"namespace prefix to add to key"
:resolve
{
:typemap
:values
{
:typesymbol
any
{
:typezen/map
:zen/desc
"Any type"
tags
{
:zen/tags
:typeset
:every
{
:tags
#{
:typesymbol
schema
{
:zen/tags
:typemap
:zen/desc
"zen schema"
:keys
{
:enum
{
:typevector
:zen/desc
"Check value is in enum"
:every
{
:typemap
:keys
{
:value
{
:typeany
:confirms
{
:typeset
:zen/desc
"set of schemas to confirm"
:every
{
:tags
:typesymbol
:type
{
:tags
:typesymbol
:const
{
:typemap
:zen/desc
"Check constant"
:keys
{
:value
{
:typeany
:validation
{
:typeset
:zen/desc
"Custom validation set of functions"
:every
{
:schema-key
{
:key:type
date
{
:typemap
:keys
{
:in-past
{
:typeboolean
:in-future
{
:typeboolean
validation-fn
{
:zen/tags
:typemap
:zen/desc
"Tag for validation functions"
:keys
{
:handler
{
:typekeyword
errors
{
:confirms
:zen/tags
:zen/desc
"resource validation errors while load"
desc
{
:zen/tags
:typestring
number
{
:typemap
:zen/desc
"number primitive type"
:keys
{
:min
{
:typenumber
:max
{
:typenumber
schema-errors
{
:zen/tags
:typevector
:every
{
:typemap
:keys
{
:path
{
:typeany
:schema
{
:typeany
:type
{
:typestring
:resource
{
:typestring
:message
{
:typestring
property
{
:zen/tags
:zen/desc
"register tag as a property - i.e. global key with schema"
symbol
{
:typemap
:keys
{
:tags
{
:typeset
:zen/desc
"Check that symbol registered with specific tags"
:every
{
:typesymbol
name
{
:zen/tags
:typesymbol
file
{
:zen/tags
:typestring
:zen/desc
"file, namespace was loaded from"
operation
{
:zen/tags
:typemap
:zen/desc
"Basic operation schema"
:keys
{
:params
{
:confirms
:middleware
{
:typemap
:keys
{
:after
{
:typevector
:before
{
:typevector
:result
{
:confirms
coll
{
:zen/tags
:typemap
:keys
{
:minItems
{
:min
0
:typeinteger
:every
{
:confirms
:maxItems
{
:min
0
:typeinteger
type
{
:zen/tags
:zen/desc
"register resource as a schema type"
string
{
:typemap
:zen/desc
"sring primitive type"
:keys
{
:minLength
{
:min
0
:typeinteger
:zen/desc
"inclusive minimal length of string"
:maxLength
{
:min
0
:typeinteger
:regex
{
:typeregex
vector
{
:confirms
:zen/tags
:typemap
:keys
{
:nth
{
:key
{
:typeinteger
:typemap
:values
{
:confirms
primitive
{
:zen/tags
#{
:zen/desc
"Primitive types"
schema-result
{
:zen/tags
:typemap
:keys
{
:errors
{
:confirms
integer
{
:typemap
:zen/desc
"integer primitive type"
:keys
{
:min
{
:typeinteger
:max
{
:typeinteger
case
{
:zen/tags
:typemap
:zen/desc
"case definition is a collection of pairs :when and :then.\n Starting from first pair, go until first :when schema is valid, then it validates with :then schema"
:keys
{
:case
{
:typevector
:every
{
:require
#{
:when
:typemap
:keys
{
:when
{
:confirms
:then
{
:confirms
resource
{
:zen/tags
:typemap
:keys
{
:resourceType
{
:typestring
:id
{
:typestring
datetime
{
:typemap
:keys
{
:in-past
{
:typeboolean
:in-future
{
:typeboolean
regex
{
:typemap
:zen/desc
"regexp primitive type"