fromJson static method
override
Implementation
static InspectionLocation? fromJson(Map<String, dynamic> json) {
final normalized = _normalizeInspectionLocationJson(json);
if (normalized['PjNr'] == null || normalized['StONr'] == null) {
debugPrint(
'Skipping InspectionLocation because of missing identifiers: $json');
return null;
}
try {
return _$InspectionLocationFromJson(normalized);
} catch (e) {
debugPrint(
'Decoding InspectionLocation failed: $e\njson: $json\nnormalized: $normalized');
}
return null;
}