EventSeries.fromJson constructor

EventSeries.fromJson(
  1. Map<String, dynamic> json
)

Creates a EventSeries from JSON data.

Implementation

factory EventSeries.fromJson(Map<String, dynamic> json) {
  final tempCountJson = json['count'];
  final tempLastObservedTimeJson = json['lastObservedTime'];

  final int tempCount = tempCountJson;
  final String tempLastObservedTime = tempLastObservedTimeJson;

  return EventSeries(
    count: tempCount,
    lastObservedTime: tempLastObservedTime,
  );
}