Conditions.fromJson constructor
Deserializes a JSON-compatible map to create an instance.
Used internally, not intended for direct use by consumers. The expected map structure may change without notice.
Implementation
factory Conditions.fromJson(final Map<String, dynamic> json) {
return Conditions(
type: json['type'],
stamp: DateTime.fromMillisecondsSinceEpoch(json['stamp'], isUtc: true),
description: json['description'],
daylight: DaylightExtension.fromId(json['daylight']),
params: (json['params'] as List<dynamic>)
.map((final dynamic categoryJson) => Parameter.fromJson(categoryJson))
.toList(),
img: Img.init(json['img']),
);
}