Home | Trees | Indices | Help |
|
---|
|
object --+ | Directive --+ | IfDirective
Implementation of the py:if template directive for conditionally excluding elements from being output.
>>> from genshi.template import MarkupTemplate >>> tmpl = MarkupTemplate('''<div xmlns:py="http://genshi.edgewall.org/"> ... <b py:if="foo">${bar}</b> ... </div>''') >>> print(tmpl.generate(foo=True, bar='Hello')) <div> <b>Hello</b> </div>
Nested Classes | |
Inherited from |
Instance Methods | |||
|
|||
Inherited from Inherited from |
Class Methods | |||
|
Class Variables | |
tagname =
|
Properties | |
Inherited from Inherited from |
Method Details |
Called after the template stream has been completely parsed. This class method should return a (directive, stream) tuple. If
directive is not None, it should be an instance of the Directive
class, and gets added to the list of directives applied to the substream
at runtime.
|
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Thu Apr 22 14:10:37 2010 | http://epydoc.sourceforge.net |