How to signal object instantiation in a Collaboration/Communication Diagram?
Posted
by devoured elysium
on Stack Overflow
See other posts from Stack Overflow
or by devoured elysium
Published on 2010-05-29T18:24:22Z
Indexed on
2010/05/29
18:32 UTC
Read the original article
Hit count: 236
I'd like to know how to translate the following line of code to a Collaboration Diagram:
Food food = new Food("abc", 123);
I know that I can call an Food
's method using the following notation:
MyStaticMethod()
----------------------> --------
| |
| Food |
| |
--------
being that equivalent to
Taste taste = Food.MyStaticMethod();
and
MyInstanceMethod()
----------------------> ---------------
| |
| food : Food |
| |
---------------
is equivalent to
food.MyInstanceMethod();
but how do I signal that I want to call a given constructor on Food?
Thanks
© Stack Overflow or respective owner