public final class FillInAnswerValue extends TeacherAnswerValue<FillInAnswerValuePart,FillInResponseValue>
Constructor and Description |
---|
FillInAnswerValue(FillInAnswerValuePart avp)
Constructor
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
isMatch(FillInResponseValue response,
java.util.Map<java.lang.String,java.lang.String> args)
Determines whether a student's response matches this answer value.
|
isAllowedEvalType, isMatchDefault, validatePartsCount, validatePartsCount
equals, getValuePart, getValuePart, getValueParts, getValuePartsCount, getValuePartType, getValuePartType, getValuePartValue, getValuePartValue, hashCode, partsToList, setValueParts, setValueParts, toString, toViewString
public FillInAnswerValue(FillInAnswerValuePart avp)
avp
- Answerprotected boolean isMatch(FillInResponseValue response, java.util.Map<java.lang.String,java.lang.String> args)
TeacherAnswerValue
A matching response does not imply the given response is correct.
Your subclass can implement this method by calling the default method
#isMatchDefault(StudentResponseValue)
.
The semantics of your problem type might prevent your AnswerValue subclass from calling the isMatchDefault(StudentResponseValue) method.
One case is when the problem type does not implement a 1:1 matching of answer value parts to response value parts.
For example: A range problem is not going to match the student's response (with a single value part) to the answer value parts (which represent a lower- and upper-limit). Rather the range problem must provide an isMatch() implementation that checks if the student's response, a single-part answer value, falls between the two limits.
isMatch
in class TeacherAnswerValue<FillInAnswerValuePart,FillInResponseValue>
response
- The response to compare to this answer value.args
- Map for problem specific properties that will
be used in calculating correctness for the problem.#isMatchDefault(StudentResponseValue)
,
Answer#isMatch(StudentResponseValue)
,
AnswerValuePart#isMatch(AnswerValuePart)