Accessors in Python (getters and setters)

Ant antroy at gmail.com
Wed Jul 12 08:29:00 EDT 2006


> Yes, it is possible to name crappy accessors too (e.g set_tmp/get_tmp).
> But developers tend to pay more attention to given methods/functions
> less crappy names, at least when compared to data attributes. This

In my experience of getters and setters in Java, most developers choose
attribute names first, and then use the IDE (Java without an IDE
*really* sucks) to auto-generate the getters and setters. So most Java
developers I have worked with pay more attention to attributes than
accessor names as these are derived anyway. So I guess it depends on
who the developers are ;-)




More information about the Python-list mailing list