RPStepResult constructor

RPStepResult(
  1. {required String identifier,
  2. required String questionTitle,
  3. required RPAnswerFormat answerFormat}
)

Create a RPStepResult with a given identifier and an empty map of results.

It sets startDate to the DateTime.now(). Since these objects are instantiated together with the Step it belongs to so it can be used for measuring how much time the participant spent the given Step.

Implementation

RPStepResult({
  required super.identifier,
  required this.questionTitle,
  required this.answerFormat,
}) {
  results = {};
  startDate = DateTime.now();
}