This is the closure-template Reference Manual, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Sep 15 03:49:38 2024 GMT+0.
closure-template/closure-template.asd
closure-template/parser/defpackage.lisp
closure-template/parser/command.lisp
closure-template/parser/expression.lisp
closure-template/defpackage.lisp
closure-template/interface.lisp
closure-template/asdf.lisp
closure-template/common-lisp-backend/escape.lisp
closure-template/common-lisp-backend/common-lisp-backend.lisp
closure-template/standard-templates.lisp
closure-template/javascript-backend/javascript-backend.lisp
The main system appears first, followed by any subsystem dependency.
closure-template
babel
(system).
parse-number
(system).
esrap
(system).
iterate
(system).
closer-mop
(system).
split-sequence
(system).
alexandria
(system).
parser
(module).
defpackage.lisp
(file).
interface.lisp
(file).
asdf.lisp
(file).
common-lisp-backend
(module).
standard-templates.lisp
(file).
javascript-backend
(module).
Modules are listed depth-first from the system components tree.
closure-template/parser
closure-template
(system).
defpackage.lisp
(file).
command.lisp
(file).
expression.lisp
(file).
closure-template/common-lisp-backend
asdf.lisp
(file).
closure-template
(system).
escape.lisp
(file).
common-lisp-backend.lisp
(file).
closure-template/javascript-backend
standard-templates.lisp
(file).
closure-template
(system).
javascript-backend.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
closure-template/closure-template.asd
closure-template/parser/defpackage.lisp
closure-template/parser/command.lisp
closure-template/parser/expression.lisp
closure-template/defpackage.lisp
closure-template/interface.lisp
closure-template/asdf.lisp
closure-template/common-lisp-backend/escape.lisp
closure-template/common-lisp-backend/common-lisp-backend.lisp
closure-template/standard-templates.lisp
closure-template/javascript-backend/javascript-backend.lisp
closure-template/closure-template.asd
closure-template
(system).
closure-template/parser/defpackage.lisp
parser
(module).
*uglify*
(special variable).
closure-template-parse
(function).
lispify-name
(function).
lispify-string
(function).
not-equal
(function).
*closure-template-rules*
(special variable).
define-rule
(macro).
with-closure-template-rules
(macro).
closure-template/parser/command.lisp
defpackage.lisp
(file).
parser
(module).
call
(class).
call-data
(reader method).
call-name
(reader method).
call-namespace
(reader method).
call-params
(reader method).
comment
(class).
comment-multiline-p
(reader method).
comment-text
(reader method).
define-print-syntax
(macro).
for-code-block
(reader method).
for-command
(class).
for-range
(reader method).
for-varname
(reader method).
foreach
(class).
foreach-code-block
(reader method).
foreach-expression
(reader method).
foreach-if-empty-code
(reader method).
foreach-varname
(reader method).
if-command
(class).
if-command-options
(reader method).
literal
(class).
literal-content
(reader method).
namespace
(class).
namespace-name
(reader method).
namespace-templates
(reader method).
parse-template
(function).
print-command
(class).
print-directives
(reader method).
print-expression
(reader method).
switch-cases
(reader method).
switch-command
(class).
switch-default
(reader method).
switch-expression
(reader method).
template
(class).
template-code-block
(reader method).
template-name
(reader method).
template-properties
(reader method).
user-print-directive-p
(function).
with
(class).
with-body
(reader method).
with-vars
(reader method).
*substitiotn-map*
(special variable).
+standard-print-directives+
(special variable).
check-expression-p
(function).
define-print-directive
(macro).
define-substitions
(macro).
parse-template-name
(function).
replace-substition
(function).
simple-text-char-p
(function).
simplify-code
(function).
text-neighboring-strings
(function).
trim-whitespace
(function).
closure-template/parser/expression.lisp
command.lisp
(file).
parser
(module).
add-possible-function
(function).
arref
(class).
arref-position
(reader method).
dotref
(class).
dotref-jsname
(reader method).
dotref-name
(reader method).
fcall
(class).
fcall-args
(reader method).
fcall-jsname
(reader method).
fcall-name
(reader method).
injected-data
(class).
list-expr
(class).
list-expr-values
(reader method).
map-expr
(class).
map-expr-items
(reader method).
op-args
(reader method).
op-name
(reader method).
operator
(class).
parse-expression
(function).
ref-expr
(reader method).
var
(class).
var-jsname
(reader method).
var-name
(reader method).
*infix-ops-priority*
(special variable).
*possible-functions*
(special variable).
->prefix
(function).
define-escape-sequence
(macro).
define-operator
(macro).
not-quote-p
(function).
reduce-infix
(function).
reduce-ref
(function).
ref
(class).
replace-subseq
(function).
closure-template/defpackage.lisp
parser
(module).
closure-template
(system).
closure-template/interface.lisp
defpackage.lisp
(file).
closure-template
(system).
compile-template
(generic function).
register-print-handler
(generic function).
closure-template/asdf.lisp
defpackage.lisp
(file).
interface.lisp
(file).
closure-template
(system).
closure-template
(class).
output-files
(method).
perform
(method).
perform
(method).
closure-template/common-lisp-backend/escape.lisp
common-lisp-backend
(module).
decode-uri
(function).
encode-uri
(function).
encode-uri-component
(function).
escape-html
(function).
encode-string
(function).
closure-template/common-lisp-backend/common-lisp-backend.lisp
escape.lisp
(file).
common-lisp-backend
(module).
*default-closure-template-package*
(special variable).
*injected-data*
(special variable).
*ttable*
(special variable).
compile-cl-templates
(function).
compile-template
(method).
compile-template
(method).
compile-template
(method).
ensure-ttable-package
(function).
fetch-keys
(generic function).
fetch-property
(generic function).
package-ttable
(function).
register-print-handler
(method).
ttable
(class).
ttable-call-template
(function).
ttable-extend-package
(function).
ttable-find-template
(function).
ttable-register-template
(function).
with-user-functions
(macro).
%!=
(function).
%+
(function).
%is-nonnull
(function).
%nonblank
(generic function).
%round
(function).
%same-name
(generic function).
%str-contains
(function).
*autoescape*
(special variable).
*loops-vars*
(special variable).
*template-data*
(special variable).
*user-functions*
(special variable).
*user-print-directive-handlers*
(special variable).
add-user-function
(function).
common-lisp-backend
(class).
compile-namespace
(function).
dict
(class).
find-user-function
(function).
has-data
(function).
index
(function).
is-first
(function).
is-last
(function).
make-all-user-print-directives-handler
(function).
make-and-handler
(function).
make-boolean-expression-handler
(function).
make-call-data-handler
(function).
make-code-block-handler
(function).
make-command-handler
(generic function).
make-dict
(function).
make-expression-handler
(generic function).
make-foreach-function-handler
(function).
make-function-handler
(function).
make-if-operator-handler
(function).
make-not-handler
(function).
make-or-handler
(function).
make-param-handler
(function).
make-switch-command-handler
(function).
make-user-print-directive-handler
(function).
ttable-hash
(reader method).
ttable-prototype
(reader method).
ttable-template-name-list
(function).
write-template-atom
(function).
closure-template/standard-templates.lisp
common-lisp-backend
(module).
closure-template
(system).
closure-template/javascript-backend/javascript-backend.lisp
javascript-backend
(module).
compile-js-templates
(method).
compile-template
(method).
compile-template
(method).
compile-template
(method).
compile-template
(method).
compile-template
(method).
register-print-handler
(method).
register-print-handler
(method).
%js
(function).
*indent-level*
(special variable).
*js-custom-print-handlers*
(special variable).
*js-namespace*
(special variable).
*local-variables*
(special variable).
*requirejs-custom-print-handlers*
(special variable).
*requirejs-deps*
(special variable).
*symbol-counter*
(special variable).
+json-lisp-escaped-chars+
(special variable).
+reserved-js-words+
(special variable).
compile-to-js
(generic function).
compile-to-requirejs
(function).
copy-print-handler
(function).
javascript-backend
(class).
make-print-handler
(function).
print-handler
(structure).
print-handler-impl
(reader).
(setf print-handler-impl)
(writer).
print-handler-module
(reader).
(setf print-handler-module)
(writer).
print-handler-name
(reader).
(setf print-handler-name)
(writer).
print-handler-p
(function).
print-handler-param-converter
(reader).
(setf print-handler-param-converter)
(writer).
requirejs-backend
(class).
with-increase-indent
(macro).
with-local-var
(macro).
with-write-parenthesis
(macro).
write-call-name
(function).
write-call-with-params
(function).
write-call-without-params
(function).
write-command
(generic function).
write-custom-print-directives
(function).
write-expression
(generic function).
write-indent
(function).
write-namespace
(function).
write-namespace-body
(function).
write-namespace-declaration
(function).
write-namespace-helpers
(function).
write-template
(function).
Packages are listed by definition order.
closure-template
alexandria
.
closure-template.parser
.
common-lisp
.
iterate
.
*default-closure-template-package*
(special variable).
*injected-data*
(special variable).
*ttable*
(special variable).
closure-template
(class).
compile-cl-templates
(function).
compile-js-templates
(generic function).
compile-template
(generic function).
decode-uri
(function).
encode-uri
(function).
encode-uri-component
(function).
ensure-ttable-package
(function).
escape-html
(function).
fetch-keys
(generic function).
fetch-property
(generic function).
package-ttable
(function).
register-print-handler
(generic function).
ttable
(class).
ttable-call-template
(function).
ttable-extend-package
(function).
ttable-find-template
(function).
ttable-register-template
(function).
with-user-functions
(macro).
%!=
(function).
%+
(function).
%is-nonnull
(function).
%js
(function).
%nonblank
(generic function).
%round
(function).
%same-name
(generic function).
%str-contains
(function).
*autoescape*
(special variable).
*indent-level*
(special variable).
*js-custom-print-handlers*
(special variable).
*js-namespace*
(special variable).
*local-variables*
(special variable).
*loops-vars*
(special variable).
*requirejs-custom-print-handlers*
(special variable).
*requirejs-deps*
(special variable).
*symbol-counter*
(special variable).
*template-data*
(special variable).
*user-functions*
(special variable).
*user-print-directive-handlers*
(special variable).
+json-lisp-escaped-chars+
(special variable).
+reserved-js-words+
(special variable).
add-user-function
(function).
common-lisp-backend
(class).
compile-namespace
(function).
compile-to-js
(generic function).
compile-to-requirejs
(function).
copy-print-handler
(function).
dict
(class).
encode-string
(function).
find-user-function
(function).
has-data
(function).
index
(function).
is-first
(function).
is-last
(function).
javascript-backend
(class).
make-all-user-print-directives-handler
(function).
make-and-handler
(function).
make-boolean-expression-handler
(function).
make-call-data-handler
(function).
make-code-block-handler
(function).
make-command-handler
(generic function).
make-dict
(function).
make-expression-handler
(generic function).
make-foreach-function-handler
(function).
make-function-handler
(function).
make-if-operator-handler
(function).
make-not-handler
(function).
make-or-handler
(function).
make-param-handler
(function).
make-print-handler
(function).
make-switch-command-handler
(function).
make-user-print-directive-handler
(function).
print-handler
(structure).
print-handler-impl
(reader).
(setf print-handler-impl)
(writer).
print-handler-module
(reader).
(setf print-handler-module)
(writer).
print-handler-name
(reader).
(setf print-handler-name)
(writer).
print-handler-p
(function).
print-handler-param-converter
(reader).
(setf print-handler-param-converter)
(writer).
requirejs-backend
(class).
ttable-hash
(generic reader).
ttable-prototype
(generic reader).
ttable-template-name-list
(function).
with-increase-indent
(macro).
with-local-var
(macro).
with-write-parenthesis
(macro).
write-call-name
(function).
write-call-with-params
(function).
write-call-without-params
(function).
write-command
(generic function).
write-custom-print-directives
(function).
write-expression
(generic function).
write-indent
(function).
write-namespace
(function).
write-namespace-body
(function).
write-namespace-declaration
(function).
write-namespace-helpers
(function).
write-template
(function).
write-template-atom
(function).
closure-template.parser
common-lisp
.
esrap
.
iterate
.
*uglify*
(special variable).
add-possible-function
(function).
arref
(class).
arref-position
(generic reader).
call
(class).
call-data
(generic reader).
call-name
(generic reader).
call-namespace
(generic reader).
call-params
(generic reader).
closure-template-parse
(function).
comment
(class).
comment-multiline-p
(generic reader).
comment-text
(generic reader).
define-print-syntax
(macro).
dotref
(class).
dotref-jsname
(generic reader).
dotref-name
(generic reader).
fcall
(class).
fcall-args
(generic reader).
fcall-jsname
(generic reader).
fcall-name
(generic reader).
for-code-block
(generic reader).
for-command
(class).
for-range
(generic reader).
for-varname
(generic reader).
foreach
(class).
foreach-code-block
(generic reader).
foreach-expression
(generic reader).
foreach-if-empty-code
(generic reader).
foreach-varname
(generic reader).
if-command
(class).
if-command-options
(generic reader).
injected-data
(class).
lispify-name
(function).
lispify-string
(function).
list-expr
(class).
list-expr-values
(generic reader).
literal
(class).
literal-content
(generic reader).
map-expr
(class).
map-expr-items
(generic reader).
namespace
(class).
namespace-name
(generic reader).
namespace-templates
(generic reader).
not-equal
(function).
op-args
(generic reader).
op-name
(generic reader).
operator
(class).
parse-expression
(function).
parse-template
(function).
print-command
(class).
print-directives
(generic reader).
print-expression
(generic reader).
ref-expr
(generic reader).
switch-cases
(generic reader).
switch-command
(class).
switch-default
(generic reader).
switch-expression
(generic reader).
template
(class).
template-code-block
(generic reader).
template-name
(generic reader).
template-properties
(generic reader).
user-print-directive-p
(function).
var
(class).
var-jsname
(generic reader).
var-name
(generic reader).
with-body
(generic reader).
with-vars
(generic reader).
*closure-template-rules*
(special variable).
*infix-ops-priority*
(special variable).
*possible-functions*
(special variable).
*substitiotn-map*
(special variable).
+standard-print-directives+
(special variable).
->prefix
(function).
body
(slot).
check-expression-p
(function).
define-escape-sequence
(macro).
define-operator
(macro).
define-print-directive
(macro).
define-rule
(macro).
define-substitions
(macro).
not-quote-p
(function).
parse-template-name
(function).
reduce-infix
(function).
reduce-ref
(function).
ref
(class).
replace-subseq
(function).
replace-substition
(function).
simple-text-char-p
(function).
simplify-code
(function).
text-neighboring-strings
(function).
trim-whitespace
(function).
vars
(slot).
with-closure-template-rules
(macro).
Definitions are sorted by export status, category, package, and then by lexicographic order.
Define a syntax rule for a new user print directive which is identified by SYMBOL. EXPR defines a grammar of the new directive without whitespace and the "|" delimiter. The body of definition should contain semantic rules used to convert possible parameters of the directive
Executes body with possibility to call specified functions from templates.
Usage: (with-user-functions (("incr" #’1+))
(closure-template:compile-template :common-lisp-backend "{template test} x + 1 = {incr($x)}{/template}"))
Replaces each escape sequence in the encoded URI with the character that it represents.
Compile templates from TEMPLATE using BACKEND as target language
javascript-backend
) (templates list
)) ¶requirejs-backend
) template) ¶javascript-backend
) template) ¶(eql :requirejs-backend)
) template) ¶(eql :javascript-backend)
) template) ¶common-lisp-backend
) (templates list
)) ¶common-lisp-backend
) template) ¶(eql :common-lisp-backend)
) template) ¶for-command
)) ¶automatically generated reader method
for-command
)) ¶automatically generated reader method
for-command
)) ¶automatically generated reader method
if-command
)) ¶automatically generated reader method
print-command
)) ¶automatically generated reader method
print-command
)) ¶automatically generated reader method
expr
.
Register handler for custom print directive in BACKEND.
Directive syntax is defined by DIRECTIVE. Actual handler parameters are depend on
backend type.
(eql :requirejs-backend)
) directive &rest params) ¶Register DIRECTIVE handler for Javascript backend.
The following parameters are accepted:
:HANDLER - string which defines actual Javascript handler like "function (params, value) { }";
:FUNCTION - string with name of handler function (it should be defined elsewhere with
prototype similar to above);
:MODULE - RequireJS module which implements :FUNCTION.
:PARAMETER-CONVERTER - lambda which accepts data from parser and returns string parameters for handler.
:HANDLER or :FUNCTION are required, :PARAMETER-CONVERTER and :MODULE are optional. If :PARAMETER-CONVERTER is NIL or it returns NIL or empty string then "params" argument will be omitted in call to handler. if :MODULE not is missing it should contain URI of the RequireJS module which implements function :FUNCTION. :MODULE it not used when :HANDLER is specified
(eql :javascript-backend)
) directive &rest params) ¶Register DIRECTIVE handler for Javascript backend.
The following parameters are accepted:
:HANDLER - string which defines actual Javascript handler like "function (params, value) { }";
:FUNCTION - string with name of handler function (it should be defined elsewhere with
prototype similar to above);
:PARAMETER-CONVERTER - lambda which accepts data from parser and returns string parameters for handler.
:HANDLER or :FUNCTION are required, :PARAMETER-CONVERTER is optional. If :PARAMETER-CONVERTER is NIL or it returns NIL or empty string then "params" argument will be omitted in call to handler.
(eql :common-lisp-backend)
) directive &rest args) ¶Register handler for print DIRECTIVE in the BACKEND. ARGS must contain symbol :FUNCTION and lambda function with prototype (lambda (parameters environment value))
switch-command
)) ¶automatically generated reader method
switch-command
)) ¶automatically generated reader method
switch-command
)) ¶automatically generated reader method
expr
.
closure-template
)) ¶asdf/action
.
load-op
) (c closure-template
)) ¶asdf/action
.
compile-op
) (c closure-template
)) ¶asdf/action
.
source-file
.
common-lisp
.
"tmpl"
:varname
This slot is read-only.
:expr
This slot is read-only.
:code-block
This slot is read-only.
:if-empty-code
This slot is read-only.
:options
This slot is read-only.
common-lisp
.
:values
This slot is read-only.
:content
This slot is read-only.
:pairs
This slot is read-only.
:jsname
This slot is read-only.
Current JavaScript namespace
Convert an infix expression to prefix.
impl
.
name
.
Find the highest-precedence operator in INFIX and reduce accordingly.
symbol
) (s2 symbol
)) ¶string
) (s2 symbol
)) ¶symbol
) (s2 string
)) ¶string
) (s2 string
)) ¶number
)) ¶number
) s2) ¶for-command
)) ¶switch-command
)) ¶if-command
)) ¶print-command
)) ¶string
)) ¶Make expression handler
injected-data
)) ¶for-command
) out) ¶switch-command
) out) ¶if-command
) out) ¶print-command
) out) ¶string
) out) ¶list
) out) ¶Write expression as JavaScript
injected-data
) out) ¶string
) out) ¶integer
) out) ¶real
) out) ¶(eql :t)
) out) ¶(eql nil)
)) ¶Jump to: | %
(
-
A C D E F G H I L M N O P R S T U V W |
---|
Jump to: | %
(
-
A C D E F G H I L M N O P R S T U V W |
---|
Jump to: | *
+
A B C D E H I J M N O P R S T V |
---|
Jump to: | *
+
A B C D E H I J M N O P R S T V |
---|
Jump to: | A C D E F I J L M N O P R S T V W |
---|
Jump to: | A C D E F I J L M N O P R S T V W |
---|