Quote.fromJson constructor

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

Implementation

factory Quote.fromJson(Map<String, dynamic> json) => Quote(
      c: (json["c"] ?? 0).toDouble(),
      d: (json["d"] ?? 0).toDouble(),
      dp: (json["dp"] ?? 0).toDouble(),
      h: (json["h"] ?? 0).toDouble(),
      l: (json["l"] ?? 0).toDouble(),
      o: (json["o"] ?? 0).toDouble(),
      pc: (json["pc"] ?? 0).toDouble(),
      t: json["t"] ?? 0,
      v: (json["v"] ?? 0).toDouble(),
      //historicalPrice: HistoricalPrice.fromJson(json["historical_price"]),
      metrics:
          json["metrics"] == null ? null : Metrics.fromJson(json["metrics"]),
      // exchange: json["exchange"],
      // earningsAnnouncement: json["earningsAnnouncement"],
    );