design - Connecting modules with in an application -
While working on my hobbies programs, I split the code in background operation and GUI operations. That's why I end the Library Objects which do the actual work and the Guinea objects that represent menus, frames and so on. This is the thing of insect every time that I have a lot of objects about which other objects are about Should know. To learn about mainframes and main menus, there is a need to know about both toolbar objects such as frame and toolbar, so I terminate the reference of many objects through Constructor. While this works, I can not imagine windows or Darwin codes crossing 100 references of other components.
So my question is, what is the preferred way of passing the bunch of objects to each other's references?
: Make each object only one responsibility.
The goal here is to ensure that each object has at least the function enlite and its well-done. Then write your system with your object, in this way you get a system with small sections which are the melodies of large sections that manage parts of your system and communicate simultaneously. The dependencies between those classes are very simple.
I'm pretty sure I'm not entirely clear here, you should try to see how some large and complex object-oriented libraries (like you 're re-real-time 3D rendering Interested in.)
Comments
Post a Comment