Expression Implementations

Basic Page Template expression types.

Expression objects are created by the ExpressionEngine (they must have previously been registered with registerType()). The expression object itself is a callable object taking one argument, econtext, which is the local expression namespace.

class zope.tales.pythonexpr.PythonExpr(name, expr, engine)[source]

Evaluates a python expression by calling eval() after compiling it with compile().

Parameters:
  • expr (str) – The Python expression.

  • engine (ExpressionEngine) – The expression compiler that is creating us.