Class QuizQuestion
java.lang.Object
ai.tutor.cab302exceptionalhandlers.model.QuizQuestion
Represents a singular quiz question.
This class encapsulates the properties of a quiz question, each quiz question must have a unique message ID, a question number, and the question content itself.
- Author:
- Joshua M.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionQuizQuestion
(int messageId, int number, String question) Constructs a QuizQuestion object. -
Method Summary
-
Constructor Details
-
QuizQuestion
Constructs a QuizQuestion object.- Parameters:
messageId
- The message ID that this question belongs to, must be greater than 0number
- The question number within the quiz, must be greater than 0question
- The content of the question, must not be null or empty and must be between 1 and 100 characters- Throws:
IllegalArgumentException
- if any of the parameters are invalid
-
-
Method Details
-
getMessageId
public int getMessageId() -
getNumber
public int getNumber() -
getQuestion
-