Constructor
new Quiz(client, response)
Instantiate a Quiz object.
Name | Type | Description |
---|---|---|
client |
Client | The client that is instantiating the object. |
response |
Object | The data for the object. |
- Source:
Extends
Members
(private) _client :Client
The client that instantiated this object.
- Client
- Overrides:
- Source:
answered_by_students :Boolean
Whether or not the quiz is to be answered by students.
- Boolean
- Source:
attachment_ids :Array.<Number>
An array of IDs for attachments attached to the assignment.
- Array.<Number>
- Overrides:
- Source:
class_group_id :Number
The ID of the class group that the assignment was set for.
- Number
- Overrides:
- Source:
class_group_name :String
The name of the class group that the assignment was set for.
- String
- Overrides:
- Source:
class_year :String
The class year that the assignment was set for.
- String
- Overrides:
- Source:
community_resource_item_id :Number
The ID of the assignment community resource.
- Number
- Overrides:
- Source:
completed :Boolean
Whether or not the quiz is completed.
- Boolean
- Source:
created_at :Number
The timestamp of when the assignment was created.
- Number
- Overrides:
- Source:
description :String
The description of the assignment.
- String
- Overrides:
- Source:
due_on :Number
The timestamp of when the assignment is due.
- Number
- Overrides:
- Source:
duration :String
The duration of the assignment.
- String
- Overrides:
- Source:
duration_units :String
The duration units of the assignment.
- String
- Overrides:
- Source:
has_unread_comments :Boolean
Whether or not the assignment has unread comments.
- Boolean
- Overrides:
- Source:
id :Number
The ID of the assignment.
- Number
- Overrides:
- Source:
issued_on :Number
The timestamp of when the assignment was issued.
- Number
- Overrides:
- Source:
published_at :Number
The timestamp of when the assignment was published.
- Number
- Overrides:
- Source:
purpose :String
The purpose of the assignment.
- String
- Overrides:
- Source:
question_ids :Array.<Number>
An array of IDs to the questions in the quiz.
- Array.<Number>
- Source:
questions_time_limit :Number
The time limit for each question in seconds.
- Number
- Source:
random_order :Boolean
Whether or not the quiz is in a random order.
- Boolean
- Source:
school_id :Number
The ID of the school that the assignment is set for.
- Number
- Overrides:
- Source:
school_logo_url :String
The logo URL of of the school that the assignment is set for.
- String
- Overrides:
- Source:
school_name :String
The name of the school that the assignment is set for.
- String
- Overrides:
- Source:
subject :String
The subject of the assignment.
- String
- Overrides:
- Source:
submission_ids :Array.<Number>
An array of IDs for submissions
- Array.<Number>
- Overrides:
- Source:
submission_method_id :Number
The ID of the submission method to use.
- Number
- Overrides:
- Source:
submission_status :String
The submission status of the quiz for the client user.
- String
- Overrides:
- Source:
teacher_id :Number
The ID of the teacher who set the assignment.
- Number
- Overrides:
- Source:
teacher_name :String
The name of the teacher who set the assignment.
- String
- Overrides:
- Source:
title :String
The title of the assignment.
- String
- Overrides:
- Source:
type :String
The assignment type.
- String
- Overrides:
- Source:
updated_at :Number
The timestamp of when the assignment was last updated.
- Number
- Overrides:
- Source:
web_links :Array.<WebLink>
An array of links to web resources for the assigment.
- Array.<WebLink>
- Overrides:
- Source:
Methods
getAttachments(idsopt) → {Promise.<Array.<Attachment>>}
Get attachments attached to the assignment.
Name | Type | Attributes | Description |
---|---|---|---|
ids |
Array.<Number> |
<optional> |
The IDs of the attachments to retrieve. |
- Overrides:
- Source:
- Type
- Promise.<Array.<Attachment>>
getQuestions(idsopt) → {Promise.<Array.<QuizQuestion>>}
Get an array of questions on the Quiz.
Name | Type | Attributes | Description |
---|---|---|---|
ids |
Array.<Number> |
<optional> |
The IDs of the quiz questions to retrieve. |
- Source:
- Type
- Promise.<Array.<QuizQuestion>>
getSubmission() → {Promise.<QuizSubmission>}
Get the client user's submission to the quiz.
- Source:
- Type
- Promise.<QuizSubmission>
getSubmissionComments(idsopt) → {Promise.<Array.<QuizSubmissionComment>>}
Get comments made on the quiz's submissions.
Name | Type | Attributes | Description |
---|---|---|---|
ids |
Array.<Number> |
<optional> |
The IDs of the submission comments to retrieve. |
- Source:
- Type
- Promise.<Array.<QuizSubmissionComment>>
getSubmissions(idsopt) → {Promise.<Array.<QuizSubmission>>}
Get submissions to the quiz.
Name | Type | Attributes | Description |
---|---|---|---|
ids |
Array.<Number> |
<optional> |
The IDs of the quiz submissions to retrieve. |
- Source:
- Type
- Promise.<Array.<QuizSubmission>>
getTeacher() → {Promise.<Employee>}
Get the teacher who set the assignment.
- Overrides:
- Source:
- Type
- Promise.<Employee>