getConverter method

JsonConverter getConverter(
  1. TypeInfo type
)

Retrieves the appropriate JsonConverter for the given type.

Implementation

JsonConverter getConverter(TypeInfo type) {
  return converters.where((x) => x.canConvert(type)).firstOrNull ??
      defaultConverters.firstWhere((x) => x.canConvert(type));
}