CAMSMeasure class Null safety

A CAMS-specific Measure that holds information about what measure to collect in a task.



CAMSMeasure({required String type, String? name, String? description, bool enabled = true})
CAMSMeasure.fromJson(Map<String, dynamic> json)


$type String?
The runtime class name (type) of this object. Used for deserialization from JSON objects.
read / write, inherited
configuration Map<String, String>
A key-value map holding any application-specific configuration.
read / write
dataType DataType
The type of measure to do as a DataType.
@JsonKey(ignore: true), read-only, inherited
description String?
A longer description of this measure.
read / write
enabled bool
Whether the measure is enabled - i.e. collecting data - when the study is running. A measure is enabled as default.
read / write
fromJsonFunction Function
The function which can convert a JSON string to an object of this type.
read-only, override
hashCode int
The hash code for this object. [...]
read-only, inherited
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.
read-only, inherited
name String?
A printer-friendly name for this measure.
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
studyDeploymentId String?
The study deployment id that this measure is part of. Set on runtime.
@JsonKey(ignore: true), read / write
type String
The type of measure to do.
read / write, inherited


adapt(Measure measure) → void
Adapt this measure to a new value specified in measure.
addMeasureListener(MeasureListener listener) → void
Add a MeasureListener to this Measure.
getConfiguration(String key) String?
Get value from the configuration for this measure.
hasChanged() Future
Call this method when this measure has changed.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
removeMeasureListener(MeasureListener listener) → void
Remove a MeasureListener to this Measure.
restore() → void
Restore this measure to its original value before adapt was called. [...]
setConfiguration(String key, String configuration) → void
Add a key-value pair as configuration for this measure.
toJson() Map<String, dynamic>
Return a JSON encoding of this object.
toString() String
A string representation of this object. [...]


operator ==(Object other) bool
The equality operator. [...]