DetectorState.fromJson constructor
Implementation
factory DetectorState.fromJson(Map<String, dynamic> json) {
return DetectorState(
stateName: json['stateName'] as String,
timers: (json['timers'] as List)
.whereNotNull()
.map((e) => Timer.fromJson(e as Map<String, dynamic>))
.toList(),
variables: (json['variables'] as List)
.whereNotNull()
.map((e) => Variable.fromJson(e as Map<String, dynamic>))
.toList(),
);
}