On 05/11/2012 07:16 AM, Andreas Tawn wrote:
>> <SNIP>
>> This is a very interesting solution.
>>
>> I think it might be better suited (for my purpose) to __repr__ rather than 
>> __str__, mostly because I still lose control of the order the attributes 
>> appear.

I have no idea why using __repr__ versus __str__ would make any
difference in the order of the attributes. They're going to come out in
the order you specify, regardless of what you name your method.  If you
don't like the arbitrary order you get from the dictionary, then either
sort it, or provide an explicit list.



-- 

DaveA

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to