Given a string - execute a function by the same name
python at bdurham.com
python at bdurham.com
Tue Apr 29 08:10:41 EDT 2008
Bruno,
Thank you for your detailed analysis. I learned a lot about Python
reading everyone's responses.
For development I'm using #5: "globals().get("func")" because its
seamless to add additional functionality.
But when I release into production I'm going to shift to #3: "Place all
my functions in dictionary and lookup the function to be called". This
technique will allow me to precisely control the dynamic nature of my
application.
Thanks again to everyone who contributed on this thread.
Regards,
Malcolm
More information about the Python-list
mailing list