Results 1 to 6 of 6

Thread: Need help with class diagram

  1. #1

    Thread Starter
    New Member
    Join Date
    Dec 2012
    Posts
    2

    Need help with class diagram

    Name:  method.png
Views: 129
Size:  45.9 KB
    Name:  class.png
Views: 135
Size:  3.9 KB

    I have an assignment to design and implement a 3-tier system for a weighted score method to compare products.
    I tried to make a class diagram but I only got 2 classes "Criterion" and "Product". and not sure where to put the calculate method.



    note: "cValues" will save the values that will be multiplied by the weight to calculate the score.
    how to save this array in the database?

  2. #2
    PowerPoster Nightwalker83's Avatar
    Join Date
    Dec 2001
    Location
    Adelaide, Australia
    Posts
    13,344

    Re: Need help with class diagram

    What is the calculate method suppose to calculate?
    when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    https://get.cryptobrowser.site/30/4111672

  3. #3
    Member
    Join Date
    Oct 2012
    Posts
    37

    Re: Need help with class diagram

    I see that you made this from Excel work sheet.
    First I think that is not a good place to start off.
    What you need is a pencil and a sheet of paper.
    And you draw the class diagram yourself.
    The mistake in this is:
    First you have given the Criteria, Weight, Project1, ... as serial no 1. Which is wrong I think. Because serial 1 should start off from the actual criteria. (See I told Excel was not the place to start. And then what is confusing is Project1/Project2/etc, these should have been Product1/Product2/ etc (Correct if I am wrong).
    Have you heard about normalization?

  4. #4
    PowerPoster Nightwalker83's Avatar
    Join Date
    Dec 2001
    Location
    Adelaide, Australia
    Posts
    13,344

    Re: Need help with class diagram

    You might want to get hold of IBM Rational Products (Rational Unified Process RUP and Rational Software Architect) or similar products.
    when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    https://get.cryptobrowser.site/30/4111672

  5. #5
    PowerPoster
    Join Date
    Jul 2006
    Location
    Maldon, Essex. UK
    Posts
    6,334

    Re: Need help with class diagram

    I don't know much about class diagrams, but I think you ought to look at your 'Product' object and see how that can be 'simplified'.

    If you think about it, for each criteria and project there will be a unique score and weighted score, so it might make sense to create a third object to represent that and perhaps that's where the calculate method might be put. (I'm assuming that the calculate method takes the weight of a given critera, the score of a particular project for that criteria and produces the weighted score)

    The 'score' is not a property of the product or the cirteria; it's a function of both of them. I guess one of the objectives of the assignment is to test how you'd express that.
    Last edited by Doogle; Dec 9th, 2012 at 02:33 AM.

  6. #6

    Thread Starter
    New Member
    Join Date
    Dec 2012
    Posts
    2

    Re: Need help with class diagram

    Quote Originally Posted by Doogle View Post
    I don't know much about class diagrams, but I think you ought to look at your 'Product' object and see how that can be 'simplified'.

    If you think about it, for each criteria and project there will be a unique score and weighted score, so it might make sense to create a third object to represent that and perhaps that's where the calculate method might be put. (I'm assuming that the calculate method takes the weight of a given critera, the score of a particular project for that criteria and produces the weighted score)

    The 'score' is not a property of the product or the cirteria; it's a function of both of them. I guess one of the objectives of the assignment is to test how you'd express that.

    thank you, that helped a lot

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width