aspose file tools*
The moose likes Beginning Java and the fly likes How to implement this Class Diagram implementation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "How to implement this Class Diagram implementation" Watch "How to implement this Class Diagram implementation" New topic
Author

How to implement this Class Diagram implementation

david colais
Greenhorn

Joined: Nov 15, 2010
Posts: 29
How to implement the diagram in this link:[deleted]
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

Please just post the image next time. Not all of us want to wait almost a minute for a simple image. Or at least create a link instead of posting an url.

I would say draw some lines and text and you're done. Or just use an existing uml tool.


"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38353
    
  23
Your diagram shows two classes

It should be easy enough to implement, but you will have to work out how to get several "Item" objects associated with one "Grocery" object. Grocery is not standard English; ShoppingBasket would be more usual. That diagram, with no methods or fields, appears to be designed for writing SQL.

Please don't use zShare any more, which appears to be not far off a pornographic site, and I shall remove the link from your posting. You would have done better to copy the diagram, as Wouter has already said.
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

Why did I got the idea that you wanted to draw a diagram with Java ??

Just create 2 classes and use a Collection for the multiplicity.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to implement this Class Diagram implementation