Better class definition for Python.