• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need help understanding Component Diagrams

 
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello am doing a UML project and I got the hang of most of the UML diagrams by reading tutorials on the net. The only one I don't get is the component diagram.
What is it suppose to show.
For example am using Java Swing to design a Menu bar and attach it toa JFrame.
The menu bar has Open and Save options.
I can do the Use casue diagrams, sequnce diagrams for saving a file , the Class Digrams and so fort. But what is the Component Disgram suppose to show in a case like this?
In my opinion the Compoennet diagrams would be
1) Frame
2) Menu bar
3) Menu
4)Menu Items
I would just draw 4 compoents boxes and put those four names in it. Am I right or am I wrong. Any advise would be greatly appreciated.
I know showing a componenet diagram is kinda extreme for something as simple as a menu bar but am doing a project and its required that I show all the diagrams for the menu bar.
Thanks
Yours respectfully Avin Sinanan
 
Ranch Hand
Posts: 178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Having a background in COM/DCOM...when I hear the word component, I think interfaces.
What types of contracts do these components have (ones you've listed), how do they talk to one another?
Think of a component as being a physical 'replacable' part within a system! It could be a spell check component within a word processor. If the interfaces are well defined, then someone else can develop a faster spell check 'component' with those same interfaces, and 'replace' the older slower component without breaking the system!
[ March 05, 2002: Message edited by: Rajinder Yadav ]
 
Rajinder Yadav
Ranch Hand
Posts: 178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The menu bar as well as the menu items all derive from the MenuComponent class. Don't let the use of the word 'Component' in the class name fool you into thinking it requires a component diagram
Your menu bar could be documented with the following class hierarchy!

[ March 05, 2002: Message edited by: Rajinder Yadav ]
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic