__init__(self,
string=None,
filename=None,
parsetree=None,
encoding='utf-8',
data=None,
escape=HTML,
loader_class=LoaderFile,
parser_class=Parser,
renderer_class=Renderer,
eval_class=EvalPseudoSandbox,
escape_func=escape)
(Constructor)
| source code
|
Load (+parse) a template.
:Parameters:
-
`string,filename,parsetree`: a template-string, filename of a
template to load, or a template-parsetree. (only one of these 3 is
allowed)
-
`encoding`: encoding of the template-files (only used for
"filename")
-
`data`: data to fill into the template by default (dictionary).
This data may later be overridden when rendering the template.
-
`escape`: default-escaping for the template, may be overwritten by
the template!
-
`loader_class`
-
`parser_class`
-
`renderer_class`
-
`eval_class`
-
`escapefunc`
- Overrides:
TemplateBase.__init__
|