Skip to content

ElapsedTimeTrigger

A trigger which starts a task after elapsedTime has elapsed since the start of a study deployment, i.e. when a protocol is deployed on the phone for the first time.

Never stops sampling once started.

Inheritance
Implemented types
Annotations

Constructors

ElapsedTimeTrigger.fromJson

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

ElapsedTimeTrigger

ElapsedTimeTrigger({
  1. String? sourceDeviceRoleName,
  2. bool? requiresPrimaryDevice = true,
  3. Duration? elapsedTime,
})

Create a trigger that starts after elapsedTime has elapsed since the start of the study deployment.

Properties

elapsedTime

  1. @JsonKey(toJson: _$IsoDurationToJson, fromJson: _$IsoDurationFromJson)
Duration? elapsedTime
getter/setter pair

Elapsed time since start of the study deployment. If null, sampling starts immediately.

fromJsonFunction

Function get fromJsonFunction
override

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

Methods

toJson

Map<String, dynamic> toJson()
override

Return a JSON encoding of this object.