• 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
  • Devaka Cooray
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Jeanne Boyarsky
  • Tim Cooke
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
Bartenders:

How do I turn this UML into Java Code?

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello can someone good at java programming help me turn this UML class diagram into code here are the System requirements it should help you understand the class diagram that I have attached:

Each Course object maintains a list of the students on that course and the lecturer who
has been assigned to teach that course.

The Course object has behaviour that allow the adding and removing of students from
the course, assigning a teacher, getting a list of the currently assigned students, and the
currently assigned teacher.

Teachers are modelled as Lecturer objects. As a lecturer may teach more than one
course there is an association between Course and Lecturer. The taughtBy relationship
shows that a Course only has a single teacher, but that a lecturer may teach several
Courses.

Each Lecturer object also maintains a list of the Courses that it teaches.

There is a similar relationship between Course and Student. A course is attended by
zero or more Students, and a Student may attend multiple courses.

both Student and Lecture classes implement the Person interface.
item.

Rewrite a new class diagram to following: each student in a course has to take an exam
worth 60 percent and 4 courseworks worth 10 percent each. for each student taking the
course you will have to compute the course average mark.


uml_courses.jpg
[Thumbnail for uml_courses.jpg]
UML class diagram
 
Sheriff
Posts: 67735
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Where is your first stab at it? Please UseCodeTags when posting code.
 
Sheriff
Posts: 5552
326
IntelliJ IDE Python Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Jason, welcome to the Ranch!

This looks very much like homework, and unfortunately for you nobody is going to do your work for you. What I suggest is: have a go at the problem yourself and if you get into difficulty then come back, show us what you have done, and tell us the specific problem you are having. You are much more likely to get help that way.

Some light reading for you in the meantime:
- DoYourOwnHomework
- NotACodeMill
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello jason
i know i'm a little bit late but do you have the answer for this diagramm
 
I'm THIS CLOSE to ruling the world! Right after reading this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic