toJson method

Map<String, dynamic> toJson()

Convert to JSON map.

Implementation

Map<String, dynamic> toJson() => {
      'costs':
          costs.map((type, cost) => MapEntry(type.name, cost)),
      'multipliers':
          multipliers.map((sev, mult) => MapEntry(sev.name, mult)),
      'unit': unit,
      'threshold': threshold,
      'metricsThresholds': metricsThresholds.toJson(),
      'exclude': exclude,
    };