choiceValuePredictionResult method
bool
choiceValuePredictionResult
()
Implementation
bool choiceValuePredictionResult() {
Function eq = const ListEquality().equals;
(expectedValue as List<int>).sort();
RPStepResult resultFromResultSelector = _resultSelector.getResult();
this._predictionResult = false;
try {
List<int> results = List<int>();
(resultFromResultSelector.results[RPStepResult.DEFAULT_KEY] as List<RPChoice>).forEach((choice) {
results.add(choice.value);
});
results.sort();
if (eq(results,expectedValue)) {
this._predictionResult = true;
}
} catch (e) {
this._predictionResult = false;
}
return this._predictionResult;
}