Factory for arrays of objects in python
- by Vorac
Ok, the title might be a little misleading.
I have a Window class that draws widgets inside itself in the constructor. The widgets are all of the same type.
So I pass a list of dictionaries, which contain the parameters for each widget. This works quite nicely, but I am worried that the interface to callers is obfuscated.
That is, in order to…