This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Design Patterns and Class Diagram

 
Anderson Fonseca
Ranch Hand
Posts: 126
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

i�ve noticed some peoples asking when should put class representing design patterns in class diagram, but i read any posts where some ranchers describe your success on assignment just add class, no stereotypes, only association type, multiplicity and some cases a few attributes when needed. Due many ways to create a class diagram, i�m bit confused. Your know a rule or any book about what better choice or practice?

thanks
 
Ricardo Ferreira
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Anderson Fonseca:
Hi all,

i�ve noticed some peoples asking when should put class representing design patterns in class diagram, but i read any posts where some ranchers describe your success on assignment just add class, no stereotypes, only association type, multiplicity and some cases a few attributes when needed. Due many ways to create a class diagram, i�m bit confused. Your know a rule or any book about what better choice or practice?

thanks


Anderson,

In order to help you with your question, let me explain something very helpful.

There are two kinds of modeling. The elaboration phase defines two separated concepts for modeling. One of them is Analysis, and the other is the Design.

Analysis intends to define the business requirements of your application, and how your system will respond to meet the users needs. This formal modeling almost the times, refers to modeling entities, relationships and multiplicity.

The analysis is created without any plataform in mind. You just think in the system in terms of actors and behavior.

The design instead, talks about to refine the analysis, to meet the non functional requirements of the application. For example, you could meet a extensibility requirement of an application, using gof patterns in you model. When you perform some piece of modeling, thinking in the non functional requirements, you are designinng the application, not analysing.

So, you asked about put design patterns in your class diagram. If you need to explain your design, yes, you can put it without problems. But, if you are only analysing the system, do not use any patterns.

The certification asks you for define the design of the application. But, even asking for a designing, you can create a class diagram without any patterns. Patterns helps in the clarity of the message, talking about how to solve a specific problem, in a given context. If it is your case, use patterns.

Don�t use patterns just to say to the evaluator "Look, i know design patterns". Concentrate in pass the message, even don�t using any pattern. Component diagrams are very useful to show the architectural view of the application, in this case, patterns are appropriated.

Good Luck!
 
Vinay Singh
Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ricardo
I listen to what you are saying.I also had queries in this regard. Now in the tools I have worked, the realization and generalization is not possible to display in component diagram(Rational Rose for eg).
Also in Applying UML patterns by Craig Larman, in class diagram he has shown all the patterns.
So what is the best solution ?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic