factory MetricDefinition.fromJson(Map<String, dynamic> json) { return MetricDefinition( name: json['Name'] as String, regex: json['Regex'] as String, ); }