CarpProtocolService class

A ProtocolService that talks to the CARP Web Services.

In order to use this service and manage protocols the user must be authenticated as a researcher.

Inheritance

Constructors

CarpProtocolService()
Returns the singleton default instance of the CarpProtocolService. Before this instance can be used, it must be configured using the configure method.
factory

Properties

app CarpApp?
The CARP app associated with the CARP Web Service. Returns null if this service has not yet been configured via the configure method.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
headers Map<String, String>
The headers for any authenticated HTTP REST call to a CarpBaseService.
no setterinherited
isConfigured bool
Has this service been configured?
no setterinherited
rpcEndpointName String
The endpoint name for this service at CARP.
no setteroverride
rpcEndpointUri String
The URL for this service's endpoint at CARP.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

add(StudyProtocol protocol, [String? versionTag]) Future<void>
Add the specified study protocol.
override
addVersion(StudyProtocol protocol, [String? versionTag]) Future<void>
Add a new version for the specified study protocol, of which a previous version with the same id, ownerId, and name is already stored.
override
configure(CarpApp app) → void
Configure the this instance of a Carp Service.
inherited
configureFrom(CarpBaseService service) → void
Configure from another service which has already been configured and potentially authenticated.
inherited
createCustomProtocol(String ownerId, String name, String description, String customProtocol) Future<StudyProtocol>
Create a study protocol to be deployed to a single device which has its own way of describing study protocols that deviates from the CARP core study protocol model.
override
getAllForOwner(String ownerId) Future<List<StudyProtocol>>
Find all StudyProtocol's owned by the owner with ownerId. In the CARP web service, the ownerId is the logged in user's accountId.
override
getBy(String protocolId, [String? versionTag]) Future<StudyProtocol>
Return the StudyProtocol with the specified protocolId,
override
getVersionHistoryFor(String protocolId) Future<List<ProtocolVersion>>
Returns all stored versions for the protocol with the specified protocolId.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
updateParticipantDataConfiguration(String protocolId, String versionTag, List<ExpectedParticipantData> expectedParticipantData) Future<StudyProtocol>
Replace the expected participant data for the study protocol with the specified protocolId and versionTag with expectedParticipantData.
override

Operators

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