aspose file tools*
The moose likes OO, Patterns, UML and Refactoring and the fly likes Question on Command pattern from GoF book Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » OO, Patterns, UML and Refactoring
Bookmark "Question on Command pattern from GoF book" Watch "Question on Command pattern from GoF book" New topic
Author

Question on Command pattern from GoF book

Sai Swami
Ranch Hand

Joined: Sep 24, 2002
Posts: 51
Hi Ranchers,

Had a quick question on the Command pattern:

The Structure diagram of Command pattern in the GoF book shows a straight arrow of "Client" towards "Receiver" and a dotted arrow from "Client" to "ConcreteCommand".

Can anyone please tell me why a straight line and a dotted line if they both mean the same thing that there is a reference.


Thanks in advance,
Sai
Jelle Klap
Bartender

Joined: Mar 10, 2008
Posts: 1667
    
    7

The dotted arrow models a dependency, while the solid arrow models an association.

Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life.
Sai Swami
Ranch Hand

Joined: Sep 24, 2002
Posts: 51
Thanks a lot Jelle !
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Question on Command pattern from GoF book
 
Similar Threads
Rational XDE - create stereotype ?
about Proxy pattern
how to capture white space
Converting and casting.
how do i draw a dotted straight line on an applet.