MessageUpgradedGiftPurchaseOffer.fromJson constructor

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

Parses a MessageUpgradedGiftPurchaseOffer from TDLib JSON.

Implementation

factory MessageUpgradedGiftPurchaseOffer.fromJson(
  Map<String, dynamic> json,
) => MessageUpgradedGiftPurchaseOffer(
  gift: _readObject(json['gift'], UpgradedGift.fromJson),
  state: _readObject(json['state'], GiftPurchaseOfferState.fromJson),
  price: _readObject(json['price'], GiftResalePrice.fromJson),
  expirationDate: _readInt(json['expiration_date']),
);