Time.fromJson constructor

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

Creates a new instance of Time from a JSON object.

The JSON object should contain keys "dateTime" and "timeZone" that correspond to the parameters of Time.

Implementation

factory Time.fromJson(Map<String, dynamic> json) {
  return Time(
    dateTime: json['dateTime'],
    timeZone: json['timeZone'],
  );
}