RPActivityStep class

The concrete subclass of RPStep that represents a step in which a single Activity is presented to the user.

When a Task Widget presents an ActivityStep object, it instantiates an RPUIActivityStep object to present the step. The actual visual presentation depends on the type of RPActivityStep (e.g. RPTrailMakingActivity).

Inheritance

Constructors

RPActivityStep.new(String identifier, {bool includeInstructions = true, bool includeResults = true})
The basic constructor which returns a Activity Step. The identifier is required for ID purposes. The optional parameters includeInstructions or includeResults can be used exclude the non-test sections of the step.

Properties

$type String?
The runtime class name (type) of this object. Used for deserialization from JSON objects.
getter/setter pairinherited
fromJsonFunction Function
The function which can convert a JSON string to an object of this type.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
identifier String
A unique identifier of the Step. This identifier connects the Step to its result (RPResult) object.
finalinherited
includeInstructions bool
Boolean controlling whether to show the intruction before the test. You may include your own RPInstructionStep before, if you wish to display other instructions.
getter/setter pair
includeResults bool
Boolean controlling whether to show the results after the test.
getter/setter pair
jsonType String
Return the __type to be used for JSON serialization of this class. Default is runtimeType. Only specify this if you need another type.
no setterinherited
optional bool
If set to true the step can be skipped. In that case the result for the step will be null.
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stepWidget Widget
The widget (UI representation) of the step.
no setteroverride
text String?
The text of the Step. Different types of Steps are using the text text differently.
getter/setter pairinherited
title String
The title text. Different types of Steps are using the title text differently.
getter/setter pairinherited

Methods

calculateScore(dynamic result) → dynamic
calculateScore calculates the score for an ActivityStep.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
stepBody(dynamic onResultChange(dynamic), RPActivityEventLogger eventLogger) Widget
stepBody initiates the UI component for an ActivityStep.
toJson() Map<String, dynamic>
Return a JSON encoding of this object.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited