toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() {
  final context = this.context;
  final rank = this.rank;
  final result = this.result;
  return {
    if (context != null) 'context': context.toJson(),
    if (rank != null) 'rank': rank,
    if (result != null) 'result': result.toJson(),
  };
}