Question constructor

Question({
  1. required String question,
  2. bool singleChoice = true,
  3. bool isMandatory = false,
  4. String? errorText,
  5. Map<String, dynamic>? properties,
  6. bool isNumeric = false,
  7. bool isRating = false,
  8. required bool isStarRating,
  9. List<Option> options = const [],
  10. List<Map<String, String>>? answers,
})

Implementation

Question({
  required this.question,
  this.singleChoice = true,
  this.isMandatory = false,
  this.errorText,
  this.properties,
  this.isNumeric = false,
  this.isRating = false,
  required this.isStarRating,
  this.options = const [],
  List<Map<String,String>>? answers,
}) : answers = answers ?? [];