Home | History | Annotate | Download | only in jinja2

Lines Matching full:blocks

53 def new_context(environment, template_name, blocks, vars=None,
70 return Context(environment, parent, template_name, blocks)
80 blocks = self.__context.blocks[name]
81 return BlockReference(name, self.__context, blocks, 0)
110 'name', 'blocks', '__weakref__')
112 def __init__(self, environment, parent, name, blocks):
120 # create the initial mapping of blocks. Whenever template inheritance
121 # takes place the runtime will update this mapping with the new blocks
123 self.blocks = dict((k, [v]) for k, v in iteritems(blocks))
128 blocks = self.blocks[name]
129 index = blocks.index(current) + 1
130 blocks[index]
135 return BlockReference(name, self, blocks, index)
205 context.blocks.update((k, list(v)) for k, v in iteritems(self.blocks))