use of fi.otavanopisto.muikku.plugins.material.fieldmeta.TextFieldRightAnswer in project muikku by otavanopisto.
the class FieldTranslator method translateTextField.
public TextFieldMeta translateTextField(String name, Integer columns, Boolean autogrow, List<RightAnswer> rightAnswers, String help, String hint) {
List<TextFieldRightAnswer> translatedAnswers = new ArrayList<>();
for (fi.otavanopisto.muikku.plugins.dnm.parser.content.RightAnswer rightAnswer : rightAnswers) {
Boolean correct = rightAnswer.getPoints() != null && rightAnswer.getPoints() > 0;
translatedAnswers.add(new TextFieldRightAnswer(rightAnswer.getText(), true, false, correct));
}
return new TextFieldMeta(name, columns, autogrow, translatedAnswers, hint);
}
Aggregations