ProductInfo.fromJson constructor

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

Parses a ProductInfo from TDLib JSON.

Implementation

factory ProductInfo.fromJson(Map<String, dynamic> json) => ProductInfo(
  title: _readString(json['title']),
  description: _readObject(json['description'], FormattedText.fromJson),
  photo: _readOptional(json['photo'], Photo.fromJson),
);