DebtMetricsThresholds.fromYaml constructor
Implementation
factory DebtMetricsThresholds.fromYaml(Map<String, dynamic> yaml) =>
DebtMetricsThresholds(
maintainabilityIndex:
(yaml['maintainability-index'] as num?)?.toDouble() ?? 50.0,
cyclomaticComplexity: yaml['cyclomatic-complexity'] as int? ?? 20,
cognitiveComplexity: yaml['cognitive-complexity'] as int? ?? 15,
linesOfCode: yaml['lines-of-code'] as int? ?? 100,
);