Coercion between the strings of a feed and the values of the model, by the value types of the tag registry.
Coercion between the strings of a feed and the values of the model, by the value types of the tag registry.
The value types whose model values aren't strings, so that a string where one is expected means that the value didn't coerce.
The value types whose model values aren't strings, so that a string where one is expected means that the value didn't coerce.
(format type v)The model value v of type, written in its canonical string form.
A value that isn't of its type is written as it is. A keyword is written by its name, so that :no for a boolean stays no.
The model value `v` of `type`, written in its canonical string form. A value that isn't of its type is written as it is. A keyword is written by its name, so that :no for a boolean stays no.
(invalid? x)Whether x is the marker of an unreadable value.
Whether `x` is the marker of an unreadable value.
(of-type? type v)Whether v is a model value of type, of the kind that a string of
that type reads as. By type, that's:
Whether `v` is a model value of `type`, of the kind that a string of that type reads as. By type, that's: - :integer, a whole number that both platforms hold exactly - :decimal and :duration, a finite number - :boolean and :yes-no, a boolean - :presence, true, since a feed without the element has no value for it - :rfc2822 and :iso8601, an instant - :rrule, the map of a rule that RFC 5545 allows - :geo and :osm, the map of a geo URI or an OSM reference - any other type, a string
(parse type s)Read the string s as a value of type, or as ::invalid when it can't
be read.
The whitespace around s goes first, no-break spaces included, which
the JVM would otherwise keep and JavaScript not. An element of the type
:presence has no text, and it's true because it's there, whatever s
is.
Read the string `s` as a value of `type`, or as ::invalid when it can't be read. The whitespace around `s` goes first, no-break spaces included, which the JVM would otherwise keep and JavaScript not. An element of the type :presence has no text, and it's true because it's there, whatever `s` is.
(plain-decimal n)The number n written without an exponent, as XML consumers expect,
e.g. 5.0E-8 as "0.00000005". A number that isn't finite is written as
Clojure prints it.
The number `n` written without an exponent, as XML consumers expect, e.g. 5.0E-8 as "0.00000005". A number that isn't finite is written as Clojure prints it.
The value types that a registry entry can give an attribute or node text: the coerced types, and the types that stay strings but say what a valid value looks like.
The value types that a registry entry can give an attribute or node text: the coerced types, and the types that stay strings but say what a valid value looks like.
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 |