RPConsentDocument class

Represents the content of an informed consent document.

Research Package uses RPConsentDocument to provide content for RPVisualConsentStep where the content if presented to the participant and for RPConsentReviewStep where the user can review and sign the document. The building blocks of a consent document are sections. They hold the content which is presented and later agreed by the participant. By adding signatures to the consent document the parameters of the signature(s) to collect can be specified.

Inheritance
  • Object
  • Serializable
  • RPConsentDocument
Annotations
  • @JsonSerializable(fieldRename: FieldRename.snake, includeIfNull: false)

Constructors

RPConsentDocument({required String title, required List<RPConsentSection> sections})
RPConsentDocument.fromJson(Map<String, dynamic> json)
factory

Properties

$type String?
The runtime class name (type) of this object. Used for deserialization from JSON objects.
getter/setter pairinherited
fromJsonFunction Function
The function which can convert a JSON string to an object of this type.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
jsonType String
Return the __type to be used for JSON serialization of this class. Default is runtimeType. Only specify this if you need another type.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sections List<RPConsentSection>
The sections which hold the content of the consent document
getter/setter pair
signatures List<RPConsentSignature>
The list of signatures that are required in the document
getter/setter pair
title String
The title of the consent document
getter/setter pair

Methods

addSignature(RPConsentSignature signature) → void
Adds a signature to the list of signatures
getConsentSignatureAtIndex(int index) RPConsentSignature
Returns an RPConsentSignature from the signatures array at the given index
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Return a JSON encoding of this object.
override
toString() String
A string representation of this object.
inherited

Operators

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