Whole Tomato Software Support Forum
Whole Tomato Software Support Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Spaghetti
 Public Beta
 Composition graph [survey]
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

support
Moderator

5503 Posts

Posted - Jun 26 2012 :  11:38:06 AM  Show Profile  Visit support's Homepage  Reply with Quote
Which Composition graph best represents the following code? (looking for personal preferences)

Where spaghetti "IS" pasta that "HAS" meatballs and sauce.



Edited by - support on Jun 26 2012 4:59:06 PM

accord
Moderator

United Kingdom
2251 Posts

Posted - Jun 26 2012 :  12:27:24 PM  Show Profile  Reply with Quote
I would say B
Go to Top of Page

jschroedl
Ketchup Master

USA
54 Posts

Posted - Jun 26 2012 :  1:20:49 PM  Show Profile  Visit jschroedl's Homepage  Reply with Quote
I would say D

Edited by - jschroedl on Jun 26 2012 8:30:19 PM
Go to Top of Page

rhummer
Tomato Guru

USA
527 Posts

Posted - Jun 26 2012 :  4:29:14 PM  Show Profile  Visit rhummer's Homepage  Reply with Quote
I would say C

Tools Engineer - Raven Software
VS2005 SP2/VS2008 SP1 - VAX <LATEST> - Win 7 x64

Go to Top of Page

support
Moderator

5503 Posts

Posted - Jun 26 2012 :  5:00:29 PM  Show Profile  Visit support's Homepage  Reply with Quote
EDIT: Added option "D" above.
Go to Top of Page

feline
Moderator

United Kingdom
12804 Posts

Posted - Jun 26 2012 :  7:40:27 PM  Show Profile  Reply with Quote
Of the 4 options, just looking at the pictures on their own, and thinking about code structure, I would say A is my preferred option. But to try and represent the statement, definitely B, which better reflects what is happening.

zen is the art of being at one with the two'ness
Go to Top of Page

StefanEgo
Senior Member

45 Posts

Posted - Jun 27 2012 :  03:38:26 AM  Show Profile  Reply with Quote
B :)
Go to Top of Page

Mike ONeill
Ketchup Master

South Africa
87 Posts

Posted - Jun 29 2012 :  01:11:09 AM  Show Profile  Visit Mike ONeill's Homepage  Reply with Quote
I think B for me too

Mike
Go to Top of Page

sean
Moderator

USA
1553 Posts

Posted - Jun 29 2012 :  2:08:05 PM  Show Profile  Visit sean's Homepage  Reply with Quote
A is a hard sell for me because inheritance is upside-down.

B and C are appealing because I see standard inheritance (base at the top, most derived at the bottom, with "is a" arrows in the direction I expect them to be).

D is growing on me but I have to mentally change the meaning of the arrows from "is a" and "has a" to "is the base of" and "is in."
And an additional disconnect because it uses the same link colors as "is a" and "has a."

The question "Is water used in spaghetti?" for me is most easily answered by D but I'm not sure how often that question matters.

Whole Tomato Software

Edited by - sean on Jun 29 2012 2:12:41 PM
Go to Top of Page

mwb1100
Ketchup Master

77 Posts

Posted - Jul 09 2012 :  1:35:48 PM  Show Profile  Visit mwb1100's Homepage  Reply with Quote
I would also say B.

However, I think it would be even better if the "HAS A" link were more like the UML aggregation link for displaying the relationship between "Spaghetti <>--- Meatballs" and "Spaghetti <>--- Sauce".

I know that this wouldn't be perfect (the tool probably couldn't reasonably distinguish between aggregation and composition, for example), but I think displaying links more like UML lets the diagrams be more readily understood at first glance by someone, since UML is a widely documented and used diagram standard. Even if the diagrams aren't full-blown UML, using UML where there's reasonable UML to be used will make the diagrams less confusing. Why invent your own diagram 'language' when there's one already out there?
Go to Top of Page

feline
Moderator

United Kingdom
12804 Posts

Posted - Jul 10 2012 :  9:46:27 PM  Show Profile  Reply with Quote
mwb1100 have a look at this forum thread, about aggregation and composition, and see what you think:

http://www.wholetomato.com/forum/topic.asp?TOPIC_ID=10783

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Whole Tomato Software Support Forum © 2013 Whole Tomato Software, Inc Go To Top Of Page
Snitz Forums 2000