Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes forum!
  • 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
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Java and UML

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi folks,

I know little about UML diagrams, and i hope you guys can help me out. I've created an example to ilustrate my currently doubts:

http://img199.imageshack.us/img199/8751/licao.jpg

Can someone translate it to Java?

Thankz, best regards.

ps: Btw, the relationship between Client and Agency are *.. 1, not 1 .. 1.

 
lowercase baba
Posts: 13075
67
Chrome Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, and welcome!!! We don't really just hand out code. If you show us what you've tried, we'll be happy to help guide you towards getting it correct. So, post what you've got so far.

Note: Please, when posting java source code, surround it with 'code' tags to make it easier to read. You can click the little button above where you enter your post and they'll pop in, then paste your stuff between the ']' and the '['.

thanks!!!
 
Fernando Piovani
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

fred rosenberger wrote:Hi, and welcome!!! We don't really just hand out code. If you show us what you've tried, we'll be happy to help guide you towards getting it correct. So, post what you've got so far.

Note: Please, when posting java source code, surround it with 'code' tags to make it easier to read. You can click the little button above where you enter your post and they'll pop in, then paste your stuff between the ']' and the '['.

thanks!!!



Well, i've just asked for an example so i can understand it how do relationships between classes like in the example (one to many, many to one) works on java. This concept arent clear in my head, and i dont have an idea how to begin with.

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Fernando,

Do you know how to create classes in java? If so, a good place to start would be creating a java class for each of the objects in your model.

If not, let us know, I'm sure one of the nice people here could direct you towards a good 'getting started' tutorial.
 
Fernando Piovani
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Gabrielle Littler wrote:Hi Fernando,

Do you know how to create classes in java? If so, a good place to start would be creating a java class for each of the objects in your model.

If not, let us know, I'm sure one of the nice people here could direct you towards a good 'getting started' tutorial.



Yes, i know... In fact i've already figure it out how to do the problem of relationship with one-to-many:



Now i am trying to understand how did a class can compose another without belonging to it. Like it was said here:
In matter of fact most of these associations are unknown to me.
 
What's brown and sticky? ... a stick. Or a tiny ad.
The trailboss has a kickstarter
https://coderanch.com/t/754577/Garden-Master-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic