fDXPartyTypeFromJson function
Implementation
enums.FDXPartyType fDXPartyTypeFromJson(
Object? fDXPartyType, [
enums.FDXPartyType? defaultValue,
]) {
if (fDXPartyType is String) {
return enums.$FDXPartyTypeMap.entries
.firstWhere(
(element) =>
element.value.toLowerCase() == fDXPartyType.toLowerCase(),
orElse: () =>
const MapEntry(enums.FDXPartyType.swaggerGeneratedUnknown, ''))
.key;
}
final parsedResult = defaultValue == null
? null
: enums.$FDXPartyTypeMap.entries
.firstWhereOrNull((element) => element.value == defaultValue)
?.key;
return parsedResult ??
defaultValue ??
enums.FDXPartyType.swaggerGeneratedUnknown;
}