PricingPhase.fromJson constructor

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

Implementation

factory PricingPhase.fromJson(Map<String, dynamic> json) => PricingPhase(
      priceAmountMicros: json.containsKey("priceAmountMicros") && json["priceAmountMicros"] != null ? json["priceAmountMicros"] : 0,
      priceCurrencyCode: json.containsKey("priceCurrencyCode") && json["priceCurrencyCode"] != null ? json["priceCurrencyCode"] : "",
      formattedPrice: json.containsKey("formattedPrice") && json["formattedPrice"] != null ? json["formattedPrice"] : "",
      billingPeriod: json.containsKey("billingPeriod") && json["billingPeriod"] != null ? json["billingPeriod"] : "",
      recurrenceMode: json.containsKey("recurrenceMode") && json["recurrenceMode"] != null ? json["recurrenceMode"] : 0,
      billingCycleCount: json.containsKey("billingCycleCount") && json["billingCycleCount"] != null ? json["billingCycleCount"] : 0,
    );