Collections Flashcards
1
Q
What is the order of class object attribute resolution?
A
- Is it in class __dict__?
- Search any super classes in order.
- Attribute error.
2
Q
What is the order of instance object attribute resolution?
A
- Is it in instance __dict__?
- Attempt to resolve on class.
- If its a class attribute - is it a function.
- If class function - convert to method and attach to the instance.