Designing the Class diagram of ScholarX

This thread will be used to discuss regarding the class diagram of ScholarX. Please Refer Design the Initial ERD of ScholarX for more details on the ScholarX ERD.

2 Likes

I’ve created the class diagram for ScholarX. Please let me know if there are any suggestions :hugs:

1 Like

Hi, @Gimhan_minion nice job with the diagram. Following are a few suggestions and questions I got while reviewing.

  1. Change fullName in User to firstName
  2. You can use Enum classes for the following:
  3. Shouldn’t mentor and mentee have a relationship?
  4. Shouldn’t the user and mentee, mentor relationship be a composition instead of aggregation?
  5. I think it’s more meaningful if you use the following notation for marking the multiplicity(Especially for Associations)
1 Like

I thought user was an abstract-class that you inherit from. What is the logic behind using composition or aggregation?

Hi @akshika47, user is not the parent of mentor or mentee. It will make more sense if you consider user like a profile. So mentor’s will have a profile and mentee’s will have a profile.

Thank you @YohanAvishke for the feedback. :hugs: I made changes in the diagram. For clearance, the relationship between a mentor and a mentee should be Aggregation right?

Thank you @YohanAvishke for the explanation. @Gimhan_minion and I think you should use composition not aggregation.

2 Likes

Great job @Gimhan_minion but I think as a mentee cannot exist without a mentor relationship should be composition

1 Like

@akshika47 @YohanAvishke Thank you :hugs: I made the necessary changes. Now the class diagram is finalized.

1 Like

This is impressive! Good Job @Gimhan_minion! :star_struck:
Could you please give me the write access? I think can improve it a bit.

1 Like

Hello there,
Thanks, @Gimhan_minion for your amazing work! I just improved it a bit.

I’ve done the following changes,

  1. Add a new superclass named BaseScholarxEntity and moved the common attributes to that. It represents an entity that is mapped with DB.
  2. Add Enum classes
  3. Rename User as Profile to avoid confusion.
    • Rename profilePic as imageUrl
    • Rename linkedin as linkedinUrl
    • Add a new attribute headline to keep the user’s headline. (ex: Software Engineer at Google)
  4. Add a new superclass named EnrolledUser ( i. Maybe we can add an attribute named program?)
  5. Extend Mentor from EnrolledUser
    • Remove description since we have the linkedinUrl and headline in the profile.
  6. Extend Mentee from EnrolledUser
    • Change submissionForm to submissionUrl

@YohanAvishke the above mentioned field name changes should be reflected in the ERD as well.

Let me know your valuable suggestions & thoughts. :hugs:

WDYT about the 4. i ? Can we add program as an attribute to the EnrolledUser?

4 Likes

Well documented and concise. Great work @jaye :heart_eyes:
I think it’s better if we could keep a program attribute in EnrolledUser class so that we can get the particular program a mentee or a mentor is assigned to straight away, If we use this structure we have to check the program of the mentor a given mentee has applied for, to get that mentees program.

Hi @jaye nice job with the diagram

Small suggestion what if we change the BaseScholarxEntity to IdAndAuditModel?


I think this is better. Since there might be a use case to find mentees of a program. Which then can be directly achieved.


Sure

Thanks, Heshan!

Yeah, good suggestion. I added named it a Base Entity because there might be more common attributes in the future. WDYT? (Inspired by OpenMRS & Netflix OSS)

I was thinking there might be ScholarX classes in the future that don’t inherit from BaseScholarxEntity so the class name might confuse people. However, for the idea it’s better to use a generic name, but would it be better to use BaseScholarxModel as the class name?

Isn’t the term ScholarX program dependent? Like imagine we have a program which is not ScholarX but still pair mentors and mentees.

Thanks, @YohanAvishke, that’s a good idea!

We have used the term ‘scholarx’ as the platform name. But it’s independent when it comes to UI. We can run whatever the program regardless the name.