Next / Previous / Contents / Shipman's homepage

9.8. Taxon.__str__()

This method is called to convert a Taxon instance to a string. It can be useful for debugging.

xnomo3.py
# - - -   T a x o n . _ _ s t r _ _   - - -

    def __str__ ( self ):
        """Display self as a string.
        """
        return ( "%s [%s: %s] txKey=%s status=%s" %
                 ( self.eng, self.rank.name, self.sci, self.txKey,
                   self.status ) )