Trigger class

A Trigger is a specification of any condition which starts and stops Tasks at certain points in time when the condition applies. The condition can either be time-bound, based on data streams, initiated by a user of the platform, or a combination of these.

The Trigger class is abstract. Use sub-classes of Trigger implements the specific behavior / timing of a trigger.

Inheritance
Implementers
Annotations

Constructors

Trigger({String triggerId})
Trigger.fromJson(Map<String, dynamic> json)
factory

Properties

$type String
The runtime class name (type) of this object. Used for deserialization from JSON objects.
read / write, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
tasks List<Task>
The list of Tasks in this Trigger.
read / write
triggerId String
A unique id of this trigger. Is used when storing data to know what triggered the data collection.
read / write

Methods

addTask(Task task) → void
Add a Task to this Trigger
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
registerFromJson(Function fromJsonFunction) → void
Use this method to register a custom fromJson function for this class in the FromJsonFactory.
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

Static Properties

fromJsonFunction Function
read-only