Given a string - execute a function by the same name

Max M maxm at mxm.dk
Tue Apr 29 09:17:01 EDT 2008


python at bdurham.com skrev:
> Bruno,


> 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.

Just one tiny note: What you will be doing is a variation of the factory 
pattern.

So this search might give you some new ideas:

http://www.google.dk/search?hl=en&q=python+factory+pattern


-- 

hilsen/regards Max M, Denmark

http://www.mxm.dk/
IT's Mad Science




More information about the Python-list mailing list