All Questions
2 questions
0
votes
2
answers
933
views
Dependency injection in a loop?
Suppose I have a loop (in Python syntax):
xml = "<x>...</x>"
for i in arr:
j = f(x) # some complex computation
obj = Class(i, j)
xml = obj.run(xml)
Does it make sense to use ...
3
votes
4
answers
1k
views
Representing complex object dependencies
I have several classes with a reasonably complex (but acyclic) dependency graph. All the dependencies are of the form: class X instance contains an attribute of class Y. All such attributes are set ...