CurrentMetric.fromJson constructor

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

Implementation

factory CurrentMetric.fromJson(Map<String, dynamic> json) {
  return CurrentMetric(
    name: (json['Name'] as String?)?.toCurrentMetricName(),
    unit: (json['Unit'] as String?)?.toUnit(),
  );
}