fromJson static method

SimData fromJson(
  1. dynamic data
)

Implementation

static SimData fromJson(data) {
  return SimData(data['cards'] != null && data['cards'] is List
      ? data['cards']
          .map<SimCard>((_card) => SimCard.fromJson(_card))
          .toList()
      : []);
}