Class Chat
java.lang.Object
ai.tutor.cab302exceptionalhandlers.model.Chat
Represents a chat belonging to a user.
- Author:
- Joshua M.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
getId()
getName()
int
int
void
setEducationLevel
(String educationLevel) void
setId
(int id) void
void
setQuizDifficulty
(String quizDifficulty) void
setQuizLength
(int quizLength) void
setResponseAttitude
(String responseAttitude) void
setStudyArea
(String studyArea)
-
Field Details
-
MIN_QUIZ_LENGTH
public static final int MIN_QUIZ_LENGTH- See Also:
-
MAX_QUIZ_LENGTH
public static final int MAX_QUIZ_LENGTH- See Also:
-
-
Constructor Details
-
Chat
public Chat(int userId, String name, String responseAttitude, String quizDifficulty, int quizLength, String educationLevel, String studyArea) throws IllegalArgumentException Constructs a Chat object.- Parameters:
userId
- The user id that this chat belongs to, must be greater than 0name
- The name of the chat, must be 1-50 charactersresponseAttitude
- The response attitude for this chat's AI, must be 1-25 charactersquizDifficulty
- The difficulty for this chat's Quizzes, must be 1-25 charactersquizLength
- The difficulty for this chat's Quizzes, must be between 1-10educationLevel
- The education level for this chat, must be 50 characters or lessstudyArea
- The study area for this chat, must be 50 characters or less- Throws:
IllegalArgumentException
- if any of the parameters are invalid
-
-
Method Details
-
getId
public int getId() -
setId
- Throws:
IllegalArgumentException
-
getUserId
public int getUserId() -
getName
-
setName
- Throws:
IllegalArgumentException
-
getResponseAttitude
-
setResponseAttitude
- Throws:
IllegalArgumentException
-
getQuizDifficulty
-
setQuizDifficulty
- Throws:
IllegalArgumentException
-
getQuizLength
public int getQuizLength() -
setQuizLength
- Throws:
IllegalArgumentException
-
getEducationLevel
-
setEducationLevel
- Throws:
IllegalArgumentException
-
getStudyArea
-
setStudyArea
- Throws:
IllegalArgumentException
-