toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() {
  var results = this.results;
  var start = this.start;
  var limit = this.limit;
  var size = this.size;
  var links = this.links;

  final json = <String, Object?>{};
  json[r'results'] = results.map((i) => i.toJson()).toList();
  if (start != null) {
    json[r'start'] = start;
  }
  if (limit != null) {
    json[r'limit'] = limit;
  }
  if (size != null) {
    json[r'size'] = size;
  }
  if (links != null) {
    json[r'_links'] = links.toJson();
  }
  return json;
}