toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  if (this.isLocalDeleted != null) {
    json[r'isLocalDeleted'] = this.isLocalDeleted;
  } else {
    json[r'isLocalDeleted'] = null;
  }
  if (this.replyCount != null) {
    json[r'replyCount'] = this.replyCount;
  } else {
    json[r'replyCount'] = null;
  }
    json[r'feedbackResults'] = this.feedbackResults;
  if (this.isVotedUp != null) {
    json[r'isVotedUp'] = this.isVotedUp;
  } else {
    json[r'isVotedUp'] = null;
  }
  if (this.isVotedDown != null) {
    json[r'isVotedDown'] = this.isVotedDown;
  } else {
    json[r'isVotedDown'] = null;
  }
  if (this.myVoteId != null) {
    json[r'myVoteId'] = this.myVoteId;
  } else {
    json[r'myVoteId'] = null;
  }
    json[r'_id'] = this.id;
    json[r'tenantId'] = this.tenantId;
    json[r'urlId'] = this.urlId;
    json[r'url'] = this.url;
  if (this.pageTitle != null) {
    json[r'pageTitle'] = this.pageTitle;
  } else {
    json[r'pageTitle'] = null;
  }
  if (this.userId != null) {
    json[r'userId'] = this.userId;
  } else {
    json[r'userId'] = null;
  }
  if (this.anonUserId != null) {
    json[r'anonUserId'] = this.anonUserId;
  } else {
    json[r'anonUserId'] = null;
  }
    json[r'commenterName'] = this.commenterName;
  if (this.commenterLink != null) {
    json[r'commenterLink'] = this.commenterLink;
  } else {
    json[r'commenterLink'] = null;
  }
    json[r'commentHTML'] = this.commentHTML;
  if (this.parentId != null) {
    json[r'parentId'] = this.parentId;
  } else {
    json[r'parentId'] = null;
  }
  if (this.date != null) {
    json[r'date'] = this.date!.toUtc().toIso8601String();
  } else {
    json[r'date'] = null;
  }
  if (this.localDateString != null) {
    json[r'localDateString'] = this.localDateString;
  } else {
    json[r'localDateString'] = null;
  }
  if (this.votes != null) {
    json[r'votes'] = this.votes;
  } else {
    json[r'votes'] = null;
  }
  if (this.votesUp != null) {
    json[r'votesUp'] = this.votesUp;
  } else {
    json[r'votesUp'] = null;
  }
  if (this.votesDown != null) {
    json[r'votesDown'] = this.votesDown;
  } else {
    json[r'votesDown'] = null;
  }
  if (this.expireAt != null) {
    json[r'expireAt'] = this.expireAt!.toUtc().toIso8601String();
  } else {
    json[r'expireAt'] = null;
  }
  if (this.reviewed != null) {
    json[r'reviewed'] = this.reviewed;
  } else {
    json[r'reviewed'] = null;
  }
  if (this.avatarSrc != null) {
    json[r'avatarSrc'] = this.avatarSrc;
  } else {
    json[r'avatarSrc'] = null;
  }
  if (this.isSpam != null) {
    json[r'isSpam'] = this.isSpam;
  } else {
    json[r'isSpam'] = null;
  }
  if (this.permNotSpam != null) {
    json[r'permNotSpam'] = this.permNotSpam;
  } else {
    json[r'permNotSpam'] = null;
  }
  if (this.hasLinks != null) {
    json[r'hasLinks'] = this.hasLinks;
  } else {
    json[r'hasLinks'] = null;
  }
  if (this.hasCode != null) {
    json[r'hasCode'] = this.hasCode;
  } else {
    json[r'hasCode'] = null;
  }
    json[r'approved'] = this.approved;
  if (this.locale != null) {
    json[r'locale'] = this.locale;
  } else {
    json[r'locale'] = null;
  }
  if (this.isBannedUser != null) {
    json[r'isBannedUser'] = this.isBannedUser;
  } else {
    json[r'isBannedUser'] = null;
  }
  if (this.isByAdmin != null) {
    json[r'isByAdmin'] = this.isByAdmin;
  } else {
    json[r'isByAdmin'] = null;
  }
  if (this.isByModerator != null) {
    json[r'isByModerator'] = this.isByModerator;
  } else {
    json[r'isByModerator'] = null;
  }
  if (this.isPinned != null) {
    json[r'isPinned'] = this.isPinned;
  } else {
    json[r'isPinned'] = null;
  }
  if (this.isLocked != null) {
    json[r'isLocked'] = this.isLocked;
  } else {
    json[r'isLocked'] = null;
  }
  if (this.flagCount != null) {
    json[r'flagCount'] = this.flagCount;
  } else {
    json[r'flagCount'] = null;
  }
  if (this.displayLabel != null) {
    json[r'displayLabel'] = this.displayLabel;
  } else {
    json[r'displayLabel'] = null;
  }
  if (this.badges != null) {
    json[r'badges'] = this.badges;
  } else {
    json[r'badges'] = null;
  }
    json[r'verified'] = this.verified;
    json[r'feedbackIds'] = this.feedbackIds;
  if (this.isDeleted != null) {
    json[r'isDeleted'] = this.isDeleted;
  } else {
    json[r'isDeleted'] = null;
  }
  return json;
}