SmartphoneClientRepository class

A ClientRepository that runs on a smartphone. Works as a singleton. Uses the PersistenceService infrastructure to store study information persistently across app restarts.

Constructors

SmartphoneClientRepository()
Get the singleton SmartphoneClientRepository.
factory

Properties

deviceRegistration ↔ DeviceRegistration?
The DeviceRegistration used to register the client in deployments.
getter/setter pairoverride
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
studyStatusEvents Stream<StudyStatusEvent<SmartphoneStudy>>
A stream of StudyStatusEvent events generate whenever a study change state.
no setter

Methods

addStudy(SmartphoneStudy study) → void
Adds study to the repository.
override
getStudy(String studyDeploymentId, String deviceRoleName) SmartphoneStudy?
Return the study with studyDeploymentId and deviceRoleName, or null when no such study is found.
override
getStudyList() List<SmartphoneStudy>
Return all studies in this repository. May be an empty list if no studies have been added.
override
hasStudy(SmartphoneStudy study) bool
Is study in this repository?
override
init() Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeStudy(SmartphoneStudy study) → void
Remove study which is already stored in the repository. In case study is not stored in this repository, nothing happens.
override
toString() String
A string representation of this object.
override
updateStudy(SmartphoneStudy study) → void
Update a study which is already stored in the repository. In case study is not stored in this repository, nothing happens.
override

Operators

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