Liking cljdoc? Tell your friends :D

strojure.parsesso.char.core

Basic function for parsing sequences of characters.

Basic function for parsing sequences of characters.
raw docstring

++clj/s

(++ x)

Builds string from (possibly nested) collections of parsed characters and strings. To be used with [[p/with]].

Builds string from (possibly nested) collections of parsed characters and
strings. To be used with [[p/with]].
sourceraw docstring

alpha-numeric?clj/s

Parser and predicate for ASCII 7 bit alphabetic or numeric character.

Parser and predicate for ASCII 7 bit alphabetic or numeric character.
sourceraw docstring

alpha?clj/s

Parser and predicate for ASCII 7 bit alphabetic character.

Parser and predicate for ASCII 7 bit alphabetic character.
sourceraw docstring

lower-case?clj/s

Parser and predicate for ASCII 7 bit lower-case alphabetic character.

Parser and predicate for ASCII 7 bit lower-case alphabetic character.
sourceraw docstring

newlineclj/s

Parses a CRLF or LF end of line. Returns a ewline character.

Parses a CRLF or LF end of line. Returns a `
ewline` character.
sourceraw docstring

not-of?clj/s

(not-of? cs)
(not-of? cs pred-k)

Returns parser and predicate for the character c which is not in the supplied string of characters cs. See also one-of? about optional pred-k argument.

Returns parser and predicate for the character `c` which is _not_ in the
supplied string of characters `cs`. See also [[one-of?]] about optional
`pred-k` argument.
sourceraw docstring

numeric?clj/s

Parser and predicate for ASCII 7 bit numeric character.

Parser and predicate for ASCII 7 bit numeric character.
sourceraw docstring

one-of?clj/s

(one-of? cs)
(one-of? cs pred-k)

Returns parser and predicate for the character c which is in the supplied string of characters cs. Optional pred-k keyword refers to function (fn [pred-k cs] (fn [c] ...)) which returns custom predicate for chars against cs. The new pred-k should be registered using register-one-of-pred, predefined values are :default for default and :ic for case insensitive matching.

(def control-char (one-of? "EX"))

(def control-char-ignorecase (one-of? "ex" :ic))
Returns parser and predicate for the character `c` which is in the supplied
string of characters `cs`. Optional `pred-k` keyword refers to function
`(fn [pred-k cs] (fn [c] ...))` which returns custom predicate for chars
against `cs`. The new `pred-k` should be registered using
[[register-one-of-pred]], predefined values are `:default` for default and
`:ic` for case insensitive matching.

    (def control-char (one-of? "EX"))

    (def control-char-ignorecase (one-of? "ex" :ic))
sourceraw docstring

re-match?clj/s

(re-match? re)

Returns parser and predicate for the character c matching regex pattern re.

Returns parser and predicate for the character `c` matching regex pattern
`re`.
sourceraw docstring

register-one-of-predclj/s

(register-one-of-pred k f)

Associates keyword k with predicate function of the one-of? and not-of? parsers.

Associates keyword `k` with predicate function of the [[one-of?]] and
[[not-of?]] parsers.
sourceraw docstring

upper-case?clj/s

Parser and predicate for ASCII 7 bit upper-case alphabetic character.

Parser and predicate for ASCII 7 bit upper-case alphabetic character.
sourceraw docstring

whitespace?clj/s

Parser and predicate for ASCII 7 bit whitespace character.

Parser and predicate for ASCII 7 bit whitespace character.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close