48 lines
1.8 KiB
Dart
48 lines
1.8 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
part of 'cache.dart';
|
|
|
|
// **************************************************************************
|
|
// JsonSerializableGenerator
|
|
// **************************************************************************
|
|
|
|
Cache _$CacheFromJson(Map<String, dynamic> json) => Cache(
|
|
libraryTracks: (json['libraryTracks'] as List<dynamic>?)
|
|
?.map((e) => e as String)
|
|
.toList(),
|
|
)
|
|
..history = (json['history'] as List<dynamic>?)
|
|
?.map((e) => Track.fromJson(e as Map<String, dynamic>))
|
|
.toList() ??
|
|
[]
|
|
..sorts = (json['sorts'] as List<dynamic>?)
|
|
?.map((e) => Sorting.fromJson(e as Map<String, dynamic>))
|
|
.toList() ??
|
|
[]
|
|
..searchHistory = (json['searchHistory2'] as List<dynamic>?)
|
|
?.map((e) => SearchHistoryItem.fromJson(e as Map<String, dynamic>))
|
|
.toList()
|
|
..threadsWarning = json['threadsWarning'] as bool? ?? false
|
|
..lastUpdateCheck = json['lastUpdateCheck'] as int? ?? 0;
|
|
|
|
Map<String, dynamic> _$CacheToJson(Cache instance) => <String, dynamic>{
|
|
'libraryTracks': instance.libraryTracks,
|
|
'history': instance.history,
|
|
'sorts': instance.sorts,
|
|
'searchHistory2': instance.searchHistory,
|
|
'threadsWarning': instance.threadsWarning,
|
|
'lastUpdateCheck': instance.lastUpdateCheck,
|
|
};
|
|
|
|
SearchHistoryItem _$SearchHistoryItemFromJson(Map<String, dynamic> json) =>
|
|
SearchHistoryItem(
|
|
json['data'],
|
|
SearchHistoryItem._searchHistoryItemTypeFromJson(json['type'] as int),
|
|
);
|
|
|
|
Map<String, dynamic> _$SearchHistoryItemToJson(SearchHistoryItem instance) =>
|
|
<String, dynamic>{
|
|
'data': instance.data,
|
|
'type': SearchHistoryItem._searchHistoryItemTypeToJson(instance.type),
|
|
};
|