fromJson static method

StorageEntryTypeV11 fromJson(
  1. MapEntry map
)

Creates Class Object from Json

Implementation

static StorageEntryTypeV11 fromJson(MapEntry map) {
  switch (map.key) {
    case 'Plain':
      return StorageEntryTypeV11_Plain(value: map.value);
    case 'Map':
      return StorageEntryTypeV11_Map.fromJson(map.value);
    case 'DoubleMap':
      return StorageEntryTypeV11_DoubleMap.fromJson(map.value);
    default:
      throw UnexpectedTypeException('Unexpected type: ${map.key}');
  }
}