Skip to content

ActiveParticipationInvitation

An invitation to participate in an active study deployment using the assignedDevices.

Returned by ParticipationService.getActiveParticipationInvitations. A participant app shows these to let the user pick a study, and then creates a Study from studyDeploymentId and deviceRoleName. Some of the devices which the participant is invited to might already be registered. If the participant wants to use a different device, they will need to unregister the existing device first.

Annotations

Constructors

ActiveParticipationInvitation.fromJson

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

ActiveParticipationInvitation

ActiveParticipationInvitation(
  1. Participation participation,
  2. StudyInvitation invitation
)

Properties

assignedDevices

List<AssignedPrimaryDevice>? assignedDevices
getter/setter pair

The primary devices the participant is invited to use.

deviceRoleName

String? get deviceRoleName

The role name of the first assigned device; null if assignedDevices is null. Throws a StateError if the list is empty.

invitation

StudyInvitation invitation
getter/setter pair

The study description shown to the participant.

participantId

String get participantId

The ID of the participant.

participantRoleName

String? get participantRoleName

The first role name of the participant; null if assigned to all roles.

participation

Participation participation
getter/setter pair

Who participates in which study deployment.

studyDeploymentId

String get studyDeploymentId

The study deployment ID.

studyDescription

String? get studyDescription

The study description.

studyId

String? get studyId

The ID of the study; null if not available.

The study ID is extracted from StudyInvitation.applicationData of the invitation, either as a plain string or as the studyId field of a map.

studyName

String? get studyName

The study name.

Methods

toJson

Map<String, dynamic> toJson()

toString

String toString()
override

A string representation of this object.

Some classes have a default textual representation, often paired with a static parse function (like int.parse). These classes will provide the textual representation as their string representation.

Other classes have no meaningful textual representation that a program will care about. Such classes will typically override toString to provide useful information when inspecting the object, mainly for debugging or logging.