SlaInformationCompletedCycleDTO.fromJson constructor

SlaInformationCompletedCycleDTO.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory SlaInformationCompletedCycleDTO.fromJson(Map<String, Object?> json) {
  return SlaInformationCompletedCycleDTO(
    breachTime: json[r'breachTime'] != null
        ? DateDTO.fromJson(json[r'breachTime']! as Map<String, Object?>)
        : null,
    breached: json[r'breached'] as bool? ?? false,
    elapsedTime: json[r'elapsedTime'] != null
        ? DurationDTO.fromJson(json[r'elapsedTime']! as Map<String, Object?>)
        : null,
    goalDuration: json[r'goalDuration'] != null
        ? DurationDTO.fromJson(json[r'goalDuration']! as Map<String, Object?>)
        : null,
    remainingTime: json[r'remainingTime'] != null
        ? DurationDTO.fromJson(
            json[r'remainingTime']! as Map<String, Object?>)
        : null,
    startTime: json[r'startTime'] != null
        ? DateDTO.fromJson(json[r'startTime']! as Map<String, Object?>)
        : null,
    stopTime: json[r'stopTime'] != null
        ? DateDTO.fromJson(json[r'stopTime']! as Map<String, Object?>)
        : null,
  );
}