Study<TDeviceDeployment extends PrimaryDeviceDeployment> class

A study deployment, identified by studyDeploymentId, which a client device participates in with the role deviceRoleName.

A study is a ChangeNotifier and updates to a study including its deploymentStatus, status, and deployment can be listened to. Moreover, the events stream emits a StudyStatusEvent event every time the status of a study changes.

Mixed-in types

Constructors

Study(String studyDeploymentId, String deviceRoleName, [DateTime? createdOn, StudyDeploymentStatus? deploymentStatus, TDeviceDeployment? deployment])
Create a study uniquely identified by its studyDeploymentId and deviceRoleName.

Properties

createdOn DateTime
The date and time when this study was created and added to the ClientManager.
no setter
deployment → TDeviceDeployment?
The deployment for this study, when received from the deployment service.
no setter
deploymentStatus StudyDeploymentStatus?
The deployment status of this study, when known.
no setter
deviceRoleName String
The role name of the device in the deployment this study runtime participates in.
no setter
events Stream<StudyStatusEvent<Study<PrimaryDeviceDeployment>>>
Stream of study status events.
no setter
hashCode int
The hash code for this object.
no setteroverride
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
status StudyStatus
The status of this study based on deploymentStatus.
no setter
studyDeploymentId String
The ID of the deployed study for which to collect data.
no setter

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
createEvent(StudyStatusEvent<Study<PrimaryDeviceDeployment>> event) → void
Create a StudyStatusEvent of a specific type.
deploymentError([String? message]) → void
The deployment is in an error state.
deploymentStatusReceived([StudyDeploymentStatus? deploymentStatus]) → void
An updated deploymentStatus has been received. If deploymentStatus is not specified, the previously received status is marked as updated.
deploymentUpdated() → void
Mark the deployment as updated. If deployment is null, nothing happens.
deviceDeploymentReceived([TDeviceDeployment? deployment]) → void
A new primary device deployment determining what data to collect for this study has been received. If deployment is not specified, the previously received deployment is marked as updated.
dispose() → void
Discards any resources used by the object. After this is called, the object is not in a usable state and should be discarded (calls to addListener will throw after the object is disposed).
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
toString() String
A string representation of this object.
override

Operators

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