Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Controlling order of instantiation
Message
From
04/08/1997 07:11:04
Matt Mc Donnell
Mc Donnell Software Consulting
Boston, Massachusetts, United States
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00042294
Message ID:
00043021
Views:
50
>>I gotta side with JimN on this. I don't see a problem with either method. It appears to be more an issue of style. Having one or many objects depend on another object could be particularly useful in certain cases...
>
>Matt,
>
>There is a huge design difference between sibling objects beign interdependent and container-contained dependencies.
>
>Siblings are not naturally dependent on each other, while contained object are by nature dependent on their container. Therefore using a design that fosters sibling dependency is introducing a new dependency to the mix, while captializing on the already present dependency between contained objects and their container is not introducing any new dependencies.

OK Jim, I see your point.

I still believe that you can't exclude the possibility that sibling dependency is useful on occaision. And as far as turning control over to the compiler or modifications, I agree. Which is why I don't rely on 'Bring Forward'/'Push Back' to control the initialization sequence. By returning an .F. from the init of an object unless called by a Method (i.e. the Form.Init), I control the initialization order, at least for the objects of concern.

In and of itself, sibling dependency cannot be called a design flaw until you see its implemention.

Matt
Matt McDonnell
...building a better mousetrap with moldy cheese...
Previous
Reply
Map
View

Click here to load this message in the networking platform