Part type constructors. These functions aren't called directly - they're the original part constructor objects before they're extended with the generic part methods, kept for reference so their methods can be reused by other parts.
- Source:
- See:
Methods
Type Definitions
adaptive_variable_replacement_definition
A definition of a variable replacement for adaptive marking.
Properties:
Name | Type | Description |
---|---|---|
variable |
string | The name of the variable to replace. |
part |
string | The path of the part to use. |
must_go_first |
boolean | Must the referred part be answered before this part can be marked? |
alternative_result
A dictionary representing the result of marking the student's answer against a certain alternative version of the part and a given scope.
Type:
Properties:
Name | Type | Description |
---|---|---|
finalised_result |
Numbas.marking.finalised_state | A sequence of marking operations. |
values |
Object.<Numbas.jme.token> | The values of marking algorithm notes. |
credit |
number | Proportion of the available marks to award to the student. |
script_result |
Numbas.marking.marking_script_result | The unprocessed result of the marking script. |
feedbackmessage
Type:
Properties:
Name | Type | Description |
---|---|---|
op |
string | The kind of feedback. |
- Source:
- See:
-
- Numbas.parts.Part#setCredit Numbas.parts.Part#addCredit Numbas.parts.Part#multCredit Numbas.parts.Part#markingComment
markAlternatives_result
A dictionary representing the results of the markAlternatives
method.
Type:
Properties:
Name | Type | Description |
---|---|---|
result |
Numbas.parts.alternative_result | The data produced by marking against the best alternative |
best_alternative |
Numbas.parts.Part | The alternative which was used. Null if no alternative used. |
mark_result
A dictionary representing the results of marking a student's answer against a given scope, without considering alternatives.
Type:
Properties:
Name | Type | Description |
---|---|---|
finalised_result |
Numbas.marking.finalised_state | A sequence of marking operations. |
values |
Object.<Numbas.jme.token> | The values of marking algorithm notes. |
script_result |
Numbas.marking.marking_script_result | The unprocessed result of the marking script. |
marking_results
A dictionary representing the results of marking a student's answer.
Type:
Properties:
Name | Type | Description |
---|---|---|
warnings |
Array.<string> | Warning messages. |
finalised_result |
Numbas.marking.finalised_state | A sequence of marking operations. |
markingFeedback |
Array.<Numbas.parts.feedbackmessage> | Feedback messages to show to student, produced from |
values |
Object.<Numbas.jme.token> | The values of marking algorithm notes. |
credit |
number | Proportion of the available marks to award to the student. |
answered |
boolean | True if the student's answer could be marked. False if the answer was invalid - the student should change their answer and resubmit. |
partpath
A unique identifier for a Numbas.parts.Part
object, of the form qXpY[gZ|sZ]
. Numbering starts from zero, and the gZ
bit is used only when the part is a gap, and sZ
is used if it's a step.
Type:
- Source:
pre_submit_cache_result
Cached results of a pre-submit task.
Type:
Properties:
Name | Type | Description |
---|---|---|
exec_path |
string | |
studentAnswer |
Numbas.jme.token | |
results |
Array.<Object.<Numbas.jme.token>> |