fromJson method

  1. @override
OrdinalSortKey? fromJson(
  1. Map<String, dynamic>? json
)
override

Implementation

@override
OrdinalSortKey? fromJson(Map<String, dynamic>? json) {
  if (json == null) return null;

  return OrdinalSortKey(
    (json['order'] as num).toDouble(),
    name: json['name'],
  );
}