toMap method

Map<String, dynamic> toMap()

Implementation

Map<String, dynamic> toMap() {
  return {
    'questionId': questionId,
    if (selectedOptionId != null) 'selectedOptionId': selectedOptionId,
    if (freeText != null) 'freeText': freeText,
  };
}