nstcl  >  Documentation  >  nstcl-templating  >  adp_compile

Tcl Powered!

adp_compile

NAME

adp_compile — Converts an ADP template into a chunk of Tcl code.

SYNOPSIS

package require nstcl-templating ?1.0?
package require nstcl ?1.0?

::nstcl::adp_compile source_type source

::template::adp_compile source_type source

DESCRIPTION

Converts an ADP template into a chunk of Tcl code and saves it as a procedure so that subsequent re-compilation is not necessary for the same template.

source_type should be one of: "-file", "-url", or "-string". source should be the corresponding filename, URL, or string.

adp_compile returns a token (the generated procedure name actually), which should be passed to adp_eval to evaluate the compiled template.

SEE ALSO

See the adp documentation for information on the structure of ADP templates.

KEYWORDS

adp, templating, nstcl