Skip to content

Class diagram

Emil Johnsen edited this page Apr 7, 2024 · 1 revision

class-diagram

Entity Relationships:

  1. Alternative:

    • Belongs to: MultipleChoiceQuestion
    • Represents the possible options for a multiple-choice question.
  2. AlternativeRecord:

    • Belongs to: MultipleChoiceQuestionAttempt
    • Represents a user's selection for a multiple-choice question attempt.
  3. Category:

    • Has many: Quiz
    • Represents a category under which quizzes are grouped.
  4. Comment:

    • Belongs to: User, Quiz
    • Represents a user's comment on a quiz.
  5. Feedback:

    • Belongs to: User
    • Represents feedback provided by a user.
  6. MultipleChoiceQuestion:

    • Belongs to: Quiz
    • Has many: Alternative
    • Represents a question with multiple-choice options.
  7. MultipleChoiceQuestionAttempt:

    • Belongs to: QuizAttempt
    • Has many: AlternativeRecord
    • Represents a user's attempt at a multiple-choice question.
  8. PasswordResetToken:

    • Represents a token for resetting a user's password.
  9. Question:

    • Belongs to: Quiz
    • Represents a generic question.
  10. QuestionAttempt:

    • Belongs to: QuizAttempt
    • Represents a user's attempt at a question.
  11. Quiz:

    • Belongs to many: User
    • Has many: Question
    • Has many: Tag
    • Represents a quiz created by a user.
  12. QuizAttempt:

    • Belongs to: User, Quiz
    • Has many: QuestionAttempt
    • Represents a user's attempt at a quiz.
  13. Tag:

    • Has many: Quiz
    • Represents a tag associated with a quiz.
  14. TrueOrFalseQuestion:

    • Belongs to: Quiz
    • Represents a true/false question.
  15. TrueOrFalseQuestionAttempt:

    • Belongs to: QuizAttempt
    • Represents a user's attempt at a true/false question.
  16. User:

    • Has many: Quiz
    • Has many: QuizAttempt
    • Represents a user of the application.
Clone this wiki locally