aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <code@mail.matthias.benkard.de>2011-03-02 18:10:18 +0100
committerMatthias Andreas Benkard <code@mail.matthias.benkard.de>2011-03-02 18:10:18 +0100
commit835f223442bae604f3b825ec8fcf98560efee8a9 (patch)
tree7fbfd0c6eed789119bc91a77be9d92bb59d360c7
parentb3ad6185585ddd597fda8b318dfd57e7d0d25dc4 (diff)
Rename *TEMPLATE-FILTERS* to *TEMPLATE-FORMATTERS* in accordance with JSON Template terminology.
-rw-r--r--json-template.lisp14
1 files changed, 7 insertions, 7 deletions
diff --git a/json-template.lisp b/json-template.lisp
index 0e39004..4ea4b9a 100644
--- a/json-template.lisp
+++ b/json-template.lisp
@@ -19,14 +19,14 @@
(:use #:common-lisp)
(:export #:parse-template-string
#:expand-template
- #:*template-filters*))
+ #:*template-formatters*))
(in-package #:json-template)
-(defvar *template-filters*
- `(;;("html" . filter-html)
- ;;("html-attr-value" . filter-html-attr-value)
+(defvar *template-formatters*
+ `(;;("html" . format-html)
+ ;;("html-attr-value" . format-html-attr-value)
("raw" . identity)))
(defun tokenize-template-string (string)
@@ -151,11 +151,11 @@
(:text
(write-string (second thing) stream))
(:variable
- (destructuring-bind (variable filter) (cdr thing)
+ (destructuring-bind (variable formatter) (cdr thing)
(let ((value (lookup-context contexts variable)))
(format stream "~A"
- (if filter
- (funcall (cdr (assoc filter *template-filters*
+ (if formatter
+ (funcall (cdr (assoc formatter *template-formatters*
:test #'equal))
value)
value)))))