toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    'urlPattern': urlPattern,
    'latency': latency,
    'downloadThroughput': downloadThroughput,
    'uploadThroughput': uploadThroughput,
    if (connectionType != null) 'connectionType': connectionType!.toJson(),
    if (packetLoss != null) 'packetLoss': packetLoss,
    if (packetQueueLength != null) 'packetQueueLength': packetQueueLength,
    if (packetReordering != null) 'packetReordering': packetReordering,
  };
}