Comment.fromJson constructor

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

Implementation

factory Comment.fromJson(Map<String, dynamic> json) => Comment(
  id: json["id"],
  category: json["category"],
  parentAuthor: json["parent_author"],
  parentPermlink: json["parent_permlink"],
  author: json["author"],
  permlink: json["permlink"],
  title: json["title"],
  body: json["body"],
  // jsonMetadata: json["json_metadata"],
  lastUpdate: json["last_update"],
  created: json["created"],
  active: json["active"],
  lastPayout: json["last_payout"],
  depth: json["depth"],
  children: json["children"],
  netRshares: json["net_rshares"],
  absRshares: json["abs_rshares"],
  voteRshares: json["vote_rshares"],
  childrenAbsRshares: json["children_abs_rshares"],
  cashoutTime: json["cashout_time"],
  maxCashoutTime: json["max_cashout_time"],
  totalVoteWeight: json["total_vote_weight"],
  rewardWeight: json["reward_weight"],
  totalPayoutValue:
      json["total_payout_value"] != null
          ? DiscussionAsset.fromJson(json["total_payout_value"])
          : null,
  curatorPayoutValue:
      json["curator_payout_value"] != null
          ? DiscussionAsset.fromJson(json["curator_payout_value"])
          : null,
  authorRewards: json["author_rewards"],
  netVotes: json["net_votes"],
  rootComment: json["root_comment"],
  maxAcceptedPayout: json["max_accepted_payout"],
  percentHbd: json["percent_hbd"],
  allowReplies: json["allow_replies"],
  allowVotes: json["allow_votes"],
  allowCurationRewards: json["allow_curation_rewards"],
  beneficiaries:
      json["beneficiaries"] != null
          ? List<BeneficiaryRoute>.from(
            json["beneficiaries"].map((x) => BeneficiaryRoute.fromJson(x)),
          )
          : null,
);