// GENERATED CODE - DO NOT MODIFY BY HAND part of 'phone_model.dart'; // ************************************************************************** // TypeAdapterGenerator // ************************************************************************** class PhoneModelAdapter extends TypeAdapter { @override final int typeId = 0; @override PhoneModel read(BinaryReader reader) { final numOfFields = reader.readByte(); final fields = { for (int i = 0; i < numOfFields; i++) reader.readByte(): reader.read(), }; return PhoneModel( title: fields[0] as String?, time: fields[1] as String?, state: fields[2] as bool?, phoneList: (fields[3] as List?)?.cast(), ); } @override void write(BinaryWriter writer, PhoneModel obj) { writer ..writeByte(4) ..writeByte(0) ..write(obj.title) ..writeByte(1) ..write(obj.time) ..writeByte(2) ..write(obj.state) ..writeByte(3) ..write(obj.phoneList); } @override int get hashCode => typeId.hashCode; @override bool operator ==(Object other) => identical(this, other) || other is PhoneModelAdapter && runtimeType == other.runtimeType && typeId == other.typeId; } class PhoneNumAdapter extends TypeAdapter { @override final int typeId = 1; @override PhoneNum read(BinaryReader reader) { final numOfFields = reader.readByte(); final fields = { for (int i = 0; i < numOfFields; i++) reader.readByte(): reader.read(), }; return PhoneNum( name: fields[0] as String?, phone: fields[1] as String?, state: fields[2] as bool?, ); } @override void write(BinaryWriter writer, PhoneNum obj) { writer ..writeByte(3) ..writeByte(0) ..write(obj.name) ..writeByte(1) ..write(obj.phone) ..writeByte(2) ..write(obj.state); } @override int get hashCode => typeId.hashCode; @override bool operator ==(Object other) => identical(this, other) || other is PhoneNumAdapter && runtimeType == other.runtimeType && typeId == other.typeId; } // ************************************************************************** // JsonSerializableGenerator // ************************************************************************** PhoneModel _$PhoneModelFromJson(Map json) => PhoneModel( title: json['title'] as String?, time: json['time'] as String?, state: json['state'] as bool?, phoneList: (json['phoneList'] as List?) ?.map((e) => PhoneNum.fromJson(e as Map)) .toList(), ); PhoneNum _$PhoneNumFromJson(Map json) => PhoneNum( name: json['name'] as String?, phone: json['phone'] as String?, state: json['state'] as bool?, );