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