The __nonzero__ method

__nonzero__(self)

Called to implement truth value testing, and the built-in operation bool; should return False or True, or their integer equivalents 0 or 1. When this method is not defined, __len__ is called, if it is defined. If a class defines neither __len__ nor __nonzero__, all its instances are considered true.

 

A Django site. this page was rendered by a django application in 0.01s 2011-06-21 23:11:36.946553. hosted by webfaction.