Good Form

phez.asap at gmail.com phez.asap at gmail.com
Sat Oct 21 04:17:32 EDT 2006


I am new to Python but come from a C++ background so I am trying to
connect the dots :) . I am really liking what I see so far but have
some nubee questions on what is considered good form. For one thing I
am used to class variables being accessable only through methods
instaed of directly refrenced from the object instence. From what I
have read it looks like when you access a class variable directly in
Python it has something in the background that works similar to a
getter of setter.

Would you normally write methods to retrive and set your class
variables or just refrence them directly?




More information about the Python-list mailing list