toJson static method

String toJson(
  1. int? updatedSince
)

Implementation

static String toJson(int? updatedSince) {
  return json.encode({
    'type': _kType,
    'timestamp': Timeline.now,
    'requests': [
      for (final request in _profile.values.where(
        (e) {
          return (updatedSince == null) || e.lastUpdateTime >= updatedSince;
        },
      ))
        request.toJson(),
    ],
  });
}