FrameMetric.fromJson constructor

FrameMetric.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory FrameMetric.fromJson(Map<String, dynamic> json) {
  return FrameMetric(
    frameName: json['frameName'] as String,
    threadStates: (json['threadStates'] as List)
        .whereNotNull()
        .map((e) => e as String)
        .toList(),
    type: (json['type'] as String).toMetricType(),
  );
}