7.2 ExecuteMixin Class
Albatross only supplies one class for this function; the
ExecuteMixin class. This mixin provides a ``virtual machine''
which is used to execute HTML template files.
All standard Albatross execution context classes inherit from this
class.
-
When you inherit from the ExecuteMixin class you must call
this constructor to initialise the internal variables.
-
Retrieves a macro argument from the macro execution stack. The stack
is searched from the most recently pushed dictionary for an argument
keyed by name. If no argument is found a MacroError
exception is raised.
-
Pushes a dictionary of macro arguments onto the macro execution stack.
-
Pops the most recently pushed dictionary of macro arguments from the
macro execution stack.
-
Saves accumulated content on the trap stack and then resets the
content list.
-
Joins all parts on the content list and returns the result. Sets the
content list to the value popped off the trap stack.
The content trap is useful for performing out-of-order execution of
template text. The <al-option> tag makes use of the content
trap.
-
Appends the content in data to the content list.
-
Does nothing if a content trap stack is in effect, otherwise it joins
all parts in the content list and sends it to the browser via the
send_content() method. The content list is then reset via
the reset_content() method.
-
This is an alias for flush_content().
-
Sends the content passed in the data argument to standard
output. This is overridden in the AppContext class to
redirect data to the write_content() method of the
application referenced in the app member.
-
Sets the content list to an empty list and clears the content trap
stack.
Release 1.33, documentation updated on January 04, 2006.