SmartphoneStudy class
A study configured to run on a smartphone (i.e., on a SmartPhoneClientManager).
- Inheritance
-
- Object
- Study<
SmartphoneDeployment> - SmartphoneStudy
Constructors
- SmartphoneStudy({String? studyId, required String studyDeploymentId, required String deviceRoleName, String? participantId, String? participantRoleName, DateTime? createdOn, StudyDeploymentStatus? deploymentStatus, SmartphoneDeployment? deployment})
- Create a SmartphoneStudy.
- SmartphoneStudy.fromInvitation(ActiveParticipationInvitation invitation)
-
Create a SmartphoneStudy from
invitation. -
SmartphoneStudy.fromMap(Map<
String, Object?> map) -
Create a SmartphoneStudy from a SQL Result Map.
factory
Properties
- createdOn → DateTime
-
The date and time when this study was created and added to the
ClientManager.no setterinherited - deployment → SmartphoneDeployment?
-
The deployment for this study, when received from the deployment service.
no setterinherited
- deploymentStatus → StudyDeploymentStatus?
-
The deployment status of this study, when known.
no setterinherited
- deviceRoleName → String
-
The role name of the primary device in the deployment this study runtime participates in.
no setterinherited
-
events
→ Stream<
SmartphoneStudyStatusEvent> -
Stream of study status events.
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
- isDeployed → bool
-
Is this study deployed?
no setter
- isSampling → bool
-
Is this study sampling data?
no setter
- participantId ↔ String?
-
The ID of the participant in this study.
getter/setter pair
- participantRoleName ↔ String?
-
The role of the participant in this study.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- samplingState ↔ SmartphoneDeploymentExecutorSamplingState?
-
The sampling state of this study.
getter/setter pair
- status → StudyStatus
-
The status of this study based on
deploymentStatus.no setterinherited - studyDeploymentId → String
-
The ID of the deployed study for which to collect data.
no setterinherited
- studyId ↔ String?
-
The unique id of the study in the deployment service.
getter/setter pair
Methods
-
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
createEvent(
StudyStatusEvent< Study< event) → voidPrimaryDeviceDeployment> > -
Create a
StudyStatusEventof a specifictype.inherited -
deploymentError(
[String? message]) → void -
The deployment is in an error state.
Print the optional
messageand notify listeners of a deployment error event.inherited -
deploymentStatusReceived(
[StudyDeploymentStatus? deploymentStatus]) → void -
An updated
deploymentStatushas been received. IfdeploymentStatusis not specified, the previously received status is marked as updated.inherited -
deploymentUpdated(
[String? message]) → void -
Mark the
deploymentas updated. Print the optionalmessageand notify listeners of a deployment update event. Ifdeploymentis null, nothing happens.inherited -
deviceDeploymentReceived(
[SmartphoneDeployment? deployment]) → void -
A new primary device
deploymentdetermining what data to collect for this study has been received. Ifdeploymentis not specified, the previously received deployment is marked as updated.inherited -
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.
inherited