Package picalo :: Package base :: Module Expression :: Class PicaloExpression
[show private | hide private]
[frames | no frames]

Class PicaloExpression


A class that compiles an expression. This is done so the expression and locals/globals are only compiled and determined one time rather than for each time the expression is run. It's for efficiency.
Method Summary
  __init__(self, expression, *locals)
Constructor.
  __eq__(self, other)
  __ne__(self, other)
  __repr__(self)
  __str__(self)
Returns a string representation of this expression
  evaluate(self, locals, expression_backtrack)
Runs the expression given any additional locals and globals

Method Details

__init__(self, expression, *locals)
(Constructor)

Constructor. The initial_locals and initial_globals dicts override any local or global variables

__str__(self)
(Informal representation operator)

Returns a string representation of this expression

evaluate(self, locals, expression_backtrack=[])

Runs the expression given any additional locals and globals

locals => A list of dictionaries containing mappings that override the values in locals expression_backtrack => A list of all the expression id's we've run so far, to catch circular logic.

Generated by Epydoc 2.1 on Mon Aug 20 05:38:17 2007 http://epydoc.sf.net