|
-
May 13th, 2012, 01:03 AM
#7
Re: Best Object Oriented approach for building model objects?
 Originally Posted by keang
Where did I ever say that? Admittedly what I said wasn't as clear as it might have been but in no way does it imply that.
You said this,
"I generally tend to favour composition (case 2) over inheritance (case 3) "
You introduced case 3 as a possible alternative for the OP to use. I'm pointing out that case 3 more than anything is an example of bad OO.
And that's why it shouldn't be used. Not because one prefers composition over inheritance but because inheritance as used in case 3 doesn't model the intended relationship here.
I leave it at that now.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|