calculateScore method

  1. @override
int calculateScore(
  1. dynamic result
)
override

Calculates the score for this activity step.

Classes extending this activity step can override this method with a custom scoring algorithm.

Implementation

@override
int calculateScore(dynamic result) {
  int errors = result['errors'] as int;
  return errors < 2 ? 1 : 0;
}