autoFromJson<T1> static method
Implementation
static T1? autoFromJson<T1>(
dynamic json,
T1 Function(Map<String, dynamic>) fromJson,
T1 Function(String) fromJsonStr,
) {
if (json is String && json.isNotEmpty) {
return fromJsonStr(json);
} else if (json is Map<String, dynamic>) {
return fromJson(json);
}
return null;
}