Skip to content

RPActivityResult

The result a RPActivityStep creates, populated with results, steptimes and interactions.

Inheritance
Annotations

Constructors

RPActivityResult.fromJson

RPActivityResult.fromJson(
  1. Map<String, dynamic> json
)

RPActivityResult

RPActivityResult({
  1. required String identifier,
})

Create a RPActivityResult.

Properties

fromJsonFunction

Function get fromJsonFunction
override

The function which can convert a JSON string to an object of this type.

interactions

List<Interaction> interactions
getter/setter pair

The list of Interactions used to store all relevant UI interaction from the testee.

results

Map<String, dynamic> results
getter/setter pair

The map of results with a String as identifier and generic type as value

stepTimes

StepTimes stepTimes
getter/setter pair

The StepTimes class which holds all the times starting and ending of each stage in a test.

Methods

getResultForIdentifier

dynamic getResultForIdentifier(
  1. String identifier
)

Returns result value for the given identifier from the results map Used if additional results were added.

setFinalResult

void setFinalResult(
  1. dynamic result
)

Creates an entry for the results map with the default key.

Usually it's used when there's only one result produced by the Question Body

setResultForIdentifier

void setResultForIdentifier(
  1. String identifier,
  2. dynamic result
)

Adds a result to the result map with the given identifier.

Used when the result is not a traditional answer result (e.g. signature result). Also used at Form Steps where there are multiple questions asked during a single step.

toJson

Map<String, dynamic> toJson()
override

Return a JSON encoding of this object.