// GENERATED CODE - DO NOT MODIFY BY HAND part of 'imagini_graphql.graphql.dart'; // ************************************************************************** // JsonSerializableGenerator // ************************************************************************** Login$Query$AuthResponse$Device _$Login$Query$AuthResponse$DeviceFromJson( Map json) { return Login$Query$AuthResponse$Device()..id = json['id'] as String; } Map _$Login$Query$AuthResponse$DeviceToJson( Login$Query$AuthResponse$Device instance) => { 'id': instance.id, }; Login$Query$AuthResponse _$Login$Query$AuthResponseFromJson( Map json) { return Login$Query$AuthResponse() ..result = _$enumDecodeNullable(_$AuthResultEnumMap, json['result'], unknownValue: AuthResult.artemisUnknown) ..device = json['device'] == null ? null : Login$Query$AuthResponse$Device.fromJson( json['device'] as Map); } Map _$Login$Query$AuthResponseToJson( Login$Query$AuthResponse instance) => { 'result': _$AuthResultEnumMap[instance.result], 'device': instance.device?.toJson(), }; T _$enumDecode( Map enumValues, dynamic source, { T unknownValue, }) { if (source == null) { throw ArgumentError('A value must be provided. Supported values: ' '${enumValues.values.join(', ')}'); } final value = enumValues.entries .singleWhere((e) => e.value == source, orElse: () => null) ?.key; if (value == null && unknownValue == null) { throw ArgumentError('`$source` is not one of the supported values: ' '${enumValues.values.join(', ')}'); } return value ?? unknownValue; } T _$enumDecodeNullable( Map enumValues, dynamic source, { T unknownValue, }) { if (source == null) { return null; } return _$enumDecode(enumValues, source, unknownValue: unknownValue); } const _$AuthResultEnumMap = { AuthResult.success: 'Success', AuthResult.failure: 'Failure', AuthResult.artemisUnknown: 'ARTEMIS_UNKNOWN', }; Login$Query _$Login$QueryFromJson(Map json) { return Login$Query() ..login = json['login'] == null ? null : Login$Query$AuthResponse.fromJson( json['login'] as Map); } Map _$Login$QueryToJson(Login$Query instance) => { 'login': instance.login?.toJson(), }; CreateMediaItem$Mutation$MediaItem _$CreateMediaItem$Mutation$MediaItemFromJson( Map json) { return CreateMediaItem$Mutation$MediaItem() ..id = json['id'] as String ..createdAt = json['createdAt'] == null ? null : DateTime.parse(json['createdAt'] as String) ..updatedAt = json['updatedAt'] == null ? null : DateTime.parse(json['updatedAt'] as String) ..exifDate = json['exifDate'] == null ? null : DateTime.parse(json['exifDate'] as String) ..latitude = (json['latitude'] as num)?.toDouble() ..longitude = (json['longitude'] as num)?.toDouble() ..isVideo = json['isVideo'] as bool ..fileName = json['fileName'] as String ..origName = json['origName'] as String ..userID = json['userID'] as String; } Map _$CreateMediaItem$Mutation$MediaItemToJson( CreateMediaItem$Mutation$MediaItem instance) => { 'id': instance.id, 'createdAt': instance.createdAt?.toIso8601String(), 'updatedAt': instance.updatedAt?.toIso8601String(), 'exifDate': instance.exifDate?.toIso8601String(), 'latitude': instance.latitude, 'longitude': instance.longitude, 'isVideo': instance.isVideo, 'fileName': instance.fileName, 'origName': instance.origName, 'userID': instance.userID, }; CreateMediaItem$Mutation _$CreateMediaItem$MutationFromJson( Map json) { return CreateMediaItem$Mutation() ..createMediaItem = json['createMediaItem'] == null ? null : CreateMediaItem$Mutation$MediaItem.fromJson( json['createMediaItem'] as Map); } Map _$CreateMediaItem$MutationToJson( CreateMediaItem$Mutation instance) => { 'createMediaItem': instance.createMediaItem?.toJson(), }; LoginArguments _$LoginArgumentsFromJson(Map json) { return LoginArguments( user: json['user'] as String, password: json['password'] as String, deviceID: json['deviceID'] as String, ); } Map _$LoginArgumentsToJson(LoginArguments instance) => { 'user': instance.user, 'password': instance.password, 'deviceID': instance.deviceID, }; CreateMediaItemArguments _$CreateMediaItemArgumentsFromJson( Map json) { return CreateMediaItemArguments( file: fromGraphQLUploadToDartMultipartFile(json['file'] as MultipartFile), ); } Map _$CreateMediaItemArgumentsToJson( CreateMediaItemArguments instance) => { 'file': fromDartMultipartFileToGraphQLUpload(instance.file), };