Home | Trees | Indices | Help |
|
---|
|
object --+ | LookupBase --+ | LenientLookup
Default variable lookup mechanism for expressions.
When an undefined variable is referenced using this lookup style, the reference evaluates to an instance of the Undefined class:
>>> expr = Expression('nothing', lookup='lenient') >>> undef = expr.evaluate({}) >>> undef <Undefined 'nothing'>
The same will happen when a non-existing attribute or item is accessed on an existing object:
>>> expr = Expression('something.nil', lookup='lenient') >>> expr.evaluate({'something': dict()}) <Undefined 'nil'>
See the documentation of the Undefined class for details on the behavior of such objects.
See Also: StrictLookup
Instance Methods | |
Inherited from |
Class Methods | |||
|
|||
Inherited from |
Properties | |
Inherited from |
Method Details |
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Thu Apr 22 14:10:37 2010 | http://epydoc.sourceforge.net |