Common Lisp library for validataion and transformation of string data
Common Lisp
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src
t
COPYING
README.rst
data-sift.asd

README.rst

DATA-SIFT is a Common Lisp data validation and transformation library. Inspired by cl-data-format-validation and WTForms validators.

Usage

CL-USER> (data-sift:sift '(integer :min-value 0 :max-value 20) "15")
15
CL-USER (funcall (data-sift:compile-rule '(number :min-value 0)) "123.456")
123.456

Built-in validators

  • string (&key strip (min-length 0) max-length message)
  • integer (&key min-value max-value message)
  • number (&key min-value max-value message)
  • regexp (&key regex message case-insensitive-mode multi-line-mode single-line-mode extended-mode)
  • email (&key message)
  • ip-address (&key message)