Files
eatvio_app/lib/features/diary/models/consultant_comment_model.freezed.dart
2025-04-24 04:20:24 +07:00

582 lines
19 KiB
Dart

// coverage:ignore-file
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
part of 'consultant_comment_model.dart';
// **************************************************************************
// FreezedGenerator
// **************************************************************************
T _$identity<T>(T value) => value;
final _privateConstructorUsedError = UnsupportedError(
'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models');
ConsultantCommentModel _$ConsultantCommentModelFromJson(
Map<String, dynamic> json) {
return _ConsultantCommentModel.fromJson(json);
}
/// @nodoc
mixin _$ConsultantCommentModel {
String? get comment => throw _privateConstructorUsedError;
@JsonKey(name: 'meals')
Map<String, MealCommentModel> get mealsComments =>
throw _privateConstructorUsedError;
List<PortionCommentModel> get portions => throw _privateConstructorUsedError;
/// Serializes this ConsultantCommentModel to a JSON map.
Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
/// Create a copy of ConsultantCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
$ConsultantCommentModelCopyWith<ConsultantCommentModel> get copyWith =>
throw _privateConstructorUsedError;
}
/// @nodoc
abstract class $ConsultantCommentModelCopyWith<$Res> {
factory $ConsultantCommentModelCopyWith(ConsultantCommentModel value,
$Res Function(ConsultantCommentModel) then) =
_$ConsultantCommentModelCopyWithImpl<$Res, ConsultantCommentModel>;
@useResult
$Res call(
{String? comment,
@JsonKey(name: 'meals') Map<String, MealCommentModel> mealsComments,
List<PortionCommentModel> portions});
}
/// @nodoc
class _$ConsultantCommentModelCopyWithImpl<$Res,
$Val extends ConsultantCommentModel>
implements $ConsultantCommentModelCopyWith<$Res> {
_$ConsultantCommentModelCopyWithImpl(this._value, this._then);
// ignore: unused_field
final $Val _value;
// ignore: unused_field
final $Res Function($Val) _then;
/// Create a copy of ConsultantCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = freezed,
Object? mealsComments = null,
Object? portions = null,
}) {
return _then(_value.copyWith(
comment: freezed == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String?,
mealsComments: null == mealsComments
? _value.mealsComments
: mealsComments // ignore: cast_nullable_to_non_nullable
as Map<String, MealCommentModel>,
portions: null == portions
? _value.portions
: portions // ignore: cast_nullable_to_non_nullable
as List<PortionCommentModel>,
) as $Val);
}
}
/// @nodoc
abstract class _$$ConsultantCommentModelImplCopyWith<$Res>
implements $ConsultantCommentModelCopyWith<$Res> {
factory _$$ConsultantCommentModelImplCopyWith(
_$ConsultantCommentModelImpl value,
$Res Function(_$ConsultantCommentModelImpl) then) =
__$$ConsultantCommentModelImplCopyWithImpl<$Res>;
@override
@useResult
$Res call(
{String? comment,
@JsonKey(name: 'meals') Map<String, MealCommentModel> mealsComments,
List<PortionCommentModel> portions});
}
/// @nodoc
class __$$ConsultantCommentModelImplCopyWithImpl<$Res>
extends _$ConsultantCommentModelCopyWithImpl<$Res,
_$ConsultantCommentModelImpl>
implements _$$ConsultantCommentModelImplCopyWith<$Res> {
__$$ConsultantCommentModelImplCopyWithImpl(
_$ConsultantCommentModelImpl _value,
$Res Function(_$ConsultantCommentModelImpl) _then)
: super(_value, _then);
/// Create a copy of ConsultantCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = freezed,
Object? mealsComments = null,
Object? portions = null,
}) {
return _then(_$ConsultantCommentModelImpl(
comment: freezed == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String?,
mealsComments: null == mealsComments
? _value._mealsComments
: mealsComments // ignore: cast_nullable_to_non_nullable
as Map<String, MealCommentModel>,
portions: null == portions
? _value._portions
: portions // ignore: cast_nullable_to_non_nullable
as List<PortionCommentModel>,
));
}
}
/// @nodoc
@JsonSerializable()
class _$ConsultantCommentModelImpl implements _ConsultantCommentModel {
_$ConsultantCommentModelImpl(
{this.comment,
@JsonKey(name: 'meals')
final Map<String, MealCommentModel> mealsComments = const {},
final List<PortionCommentModel> portions = const []})
: _mealsComments = mealsComments,
_portions = portions;
factory _$ConsultantCommentModelImpl.fromJson(Map<String, dynamic> json) =>
_$$ConsultantCommentModelImplFromJson(json);
@override
final String? comment;
final Map<String, MealCommentModel> _mealsComments;
@override
@JsonKey(name: 'meals')
Map<String, MealCommentModel> get mealsComments {
if (_mealsComments is EqualUnmodifiableMapView) return _mealsComments;
// ignore: implicit_dynamic_type
return EqualUnmodifiableMapView(_mealsComments);
}
final List<PortionCommentModel> _portions;
@override
@JsonKey()
List<PortionCommentModel> get portions {
if (_portions is EqualUnmodifiableListView) return _portions;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView(_portions);
}
@override
String toString() {
return 'ConsultantCommentModel(comment: $comment, mealsComments: $mealsComments, portions: $portions)';
}
@override
bool operator ==(Object other) {
return identical(this, other) ||
(other.runtimeType == runtimeType &&
other is _$ConsultantCommentModelImpl &&
(identical(other.comment, comment) || other.comment == comment) &&
const DeepCollectionEquality()
.equals(other._mealsComments, _mealsComments) &&
const DeepCollectionEquality().equals(other._portions, _portions));
}
@JsonKey(includeFromJson: false, includeToJson: false)
@override
int get hashCode => Object.hash(
runtimeType,
comment,
const DeepCollectionEquality().hash(_mealsComments),
const DeepCollectionEquality().hash(_portions));
/// Create a copy of ConsultantCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
@override
@pragma('vm:prefer-inline')
_$$ConsultantCommentModelImplCopyWith<_$ConsultantCommentModelImpl>
get copyWith => __$$ConsultantCommentModelImplCopyWithImpl<
_$ConsultantCommentModelImpl>(this, _$identity);
@override
Map<String, dynamic> toJson() {
return _$$ConsultantCommentModelImplToJson(
this,
);
}
}
abstract class _ConsultantCommentModel implements ConsultantCommentModel {
factory _ConsultantCommentModel(
{final String? comment,
@JsonKey(name: 'meals') final Map<String, MealCommentModel> mealsComments,
final List<PortionCommentModel> portions}) = _$ConsultantCommentModelImpl;
factory _ConsultantCommentModel.fromJson(Map<String, dynamic> json) =
_$ConsultantCommentModelImpl.fromJson;
@override
String? get comment;
@override
@JsonKey(name: 'meals')
Map<String, MealCommentModel> get mealsComments;
@override
List<PortionCommentModel> get portions;
/// Create a copy of ConsultantCommentModel
/// with the given fields replaced by the non-null parameter values.
@override
@JsonKey(includeFromJson: false, includeToJson: false)
_$$ConsultantCommentModelImplCopyWith<_$ConsultantCommentModelImpl>
get copyWith => throw _privateConstructorUsedError;
}
PortionCommentModel _$PortionCommentModelFromJson(Map<String, dynamic> json) {
return _PortionCommentModel.fromJson(json);
}
/// @nodoc
mixin _$PortionCommentModel {
String get comment => throw _privateConstructorUsedError;
int get id => throw _privateConstructorUsedError;
/// Serializes this PortionCommentModel to a JSON map.
Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
/// Create a copy of PortionCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
$PortionCommentModelCopyWith<PortionCommentModel> get copyWith =>
throw _privateConstructorUsedError;
}
/// @nodoc
abstract class $PortionCommentModelCopyWith<$Res> {
factory $PortionCommentModelCopyWith(
PortionCommentModel value, $Res Function(PortionCommentModel) then) =
_$PortionCommentModelCopyWithImpl<$Res, PortionCommentModel>;
@useResult
$Res call({String comment, int id});
}
/// @nodoc
class _$PortionCommentModelCopyWithImpl<$Res, $Val extends PortionCommentModel>
implements $PortionCommentModelCopyWith<$Res> {
_$PortionCommentModelCopyWithImpl(this._value, this._then);
// ignore: unused_field
final $Val _value;
// ignore: unused_field
final $Res Function($Val) _then;
/// Create a copy of PortionCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = null,
Object? id = null,
}) {
return _then(_value.copyWith(
comment: null == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String,
id: null == id
? _value.id
: id // ignore: cast_nullable_to_non_nullable
as int,
) as $Val);
}
}
/// @nodoc
abstract class _$$PortionCommentModelImplCopyWith<$Res>
implements $PortionCommentModelCopyWith<$Res> {
factory _$$PortionCommentModelImplCopyWith(_$PortionCommentModelImpl value,
$Res Function(_$PortionCommentModelImpl) then) =
__$$PortionCommentModelImplCopyWithImpl<$Res>;
@override
@useResult
$Res call({String comment, int id});
}
/// @nodoc
class __$$PortionCommentModelImplCopyWithImpl<$Res>
extends _$PortionCommentModelCopyWithImpl<$Res, _$PortionCommentModelImpl>
implements _$$PortionCommentModelImplCopyWith<$Res> {
__$$PortionCommentModelImplCopyWithImpl(_$PortionCommentModelImpl _value,
$Res Function(_$PortionCommentModelImpl) _then)
: super(_value, _then);
/// Create a copy of PortionCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = null,
Object? id = null,
}) {
return _then(_$PortionCommentModelImpl(
comment: null == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String,
id: null == id
? _value.id
: id // ignore: cast_nullable_to_non_nullable
as int,
));
}
}
/// @nodoc
@JsonSerializable()
class _$PortionCommentModelImpl implements _PortionCommentModel {
_$PortionCommentModelImpl({required this.comment, required this.id});
factory _$PortionCommentModelImpl.fromJson(Map<String, dynamic> json) =>
_$$PortionCommentModelImplFromJson(json);
@override
final String comment;
@override
final int id;
@override
String toString() {
return 'PortionCommentModel(comment: $comment, id: $id)';
}
@override
bool operator ==(Object other) {
return identical(this, other) ||
(other.runtimeType == runtimeType &&
other is _$PortionCommentModelImpl &&
(identical(other.comment, comment) || other.comment == comment) &&
(identical(other.id, id) || other.id == id));
}
@JsonKey(includeFromJson: false, includeToJson: false)
@override
int get hashCode => Object.hash(runtimeType, comment, id);
/// Create a copy of PortionCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
@override
@pragma('vm:prefer-inline')
_$$PortionCommentModelImplCopyWith<_$PortionCommentModelImpl> get copyWith =>
__$$PortionCommentModelImplCopyWithImpl<_$PortionCommentModelImpl>(
this, _$identity);
@override
Map<String, dynamic> toJson() {
return _$$PortionCommentModelImplToJson(
this,
);
}
}
abstract class _PortionCommentModel implements PortionCommentModel {
factory _PortionCommentModel(
{required final String comment,
required final int id}) = _$PortionCommentModelImpl;
factory _PortionCommentModel.fromJson(Map<String, dynamic> json) =
_$PortionCommentModelImpl.fromJson;
@override
String get comment;
@override
int get id;
/// Create a copy of PortionCommentModel
/// with the given fields replaced by the non-null parameter values.
@override
@JsonKey(includeFromJson: false, includeToJson: false)
_$$PortionCommentModelImplCopyWith<_$PortionCommentModelImpl> get copyWith =>
throw _privateConstructorUsedError;
}
MealCommentModel _$MealCommentModelFromJson(Map<String, dynamic> json) {
return _MealCommentModel.fromJson(json);
}
/// @nodoc
mixin _$MealCommentModel {
String get comment => throw _privateConstructorUsedError;
@JsonKey(name: 'type_no')
int get typeNumber => throw _privateConstructorUsedError;
/// Serializes this MealCommentModel to a JSON map.
Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
/// Create a copy of MealCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
$MealCommentModelCopyWith<MealCommentModel> get copyWith =>
throw _privateConstructorUsedError;
}
/// @nodoc
abstract class $MealCommentModelCopyWith<$Res> {
factory $MealCommentModelCopyWith(
MealCommentModel value, $Res Function(MealCommentModel) then) =
_$MealCommentModelCopyWithImpl<$Res, MealCommentModel>;
@useResult
$Res call({String comment, @JsonKey(name: 'type_no') int typeNumber});
}
/// @nodoc
class _$MealCommentModelCopyWithImpl<$Res, $Val extends MealCommentModel>
implements $MealCommentModelCopyWith<$Res> {
_$MealCommentModelCopyWithImpl(this._value, this._then);
// ignore: unused_field
final $Val _value;
// ignore: unused_field
final $Res Function($Val) _then;
/// Create a copy of MealCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = null,
Object? typeNumber = null,
}) {
return _then(_value.copyWith(
comment: null == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String,
typeNumber: null == typeNumber
? _value.typeNumber
: typeNumber // ignore: cast_nullable_to_non_nullable
as int,
) as $Val);
}
}
/// @nodoc
abstract class _$$MealCommentModelImplCopyWith<$Res>
implements $MealCommentModelCopyWith<$Res> {
factory _$$MealCommentModelImplCopyWith(_$MealCommentModelImpl value,
$Res Function(_$MealCommentModelImpl) then) =
__$$MealCommentModelImplCopyWithImpl<$Res>;
@override
@useResult
$Res call({String comment, @JsonKey(name: 'type_no') int typeNumber});
}
/// @nodoc
class __$$MealCommentModelImplCopyWithImpl<$Res>
extends _$MealCommentModelCopyWithImpl<$Res, _$MealCommentModelImpl>
implements _$$MealCommentModelImplCopyWith<$Res> {
__$$MealCommentModelImplCopyWithImpl(_$MealCommentModelImpl _value,
$Res Function(_$MealCommentModelImpl) _then)
: super(_value, _then);
/// Create a copy of MealCommentModel
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? comment = null,
Object? typeNumber = null,
}) {
return _then(_$MealCommentModelImpl(
comment: null == comment
? _value.comment
: comment // ignore: cast_nullable_to_non_nullable
as String,
typeNumber: null == typeNumber
? _value.typeNumber
: typeNumber // ignore: cast_nullable_to_non_nullable
as int,
));
}
}
/// @nodoc
@JsonSerializable()
class _$MealCommentModelImpl implements _MealCommentModel {
_$MealCommentModelImpl(
{required this.comment,
@JsonKey(name: 'type_no') required this.typeNumber});
factory _$MealCommentModelImpl.fromJson(Map<String, dynamic> json) =>
_$$MealCommentModelImplFromJson(json);
@override
final String comment;
@override
@JsonKey(name: 'type_no')
final int typeNumber;
@override
String toString() {
return 'MealCommentModel(comment: $comment, typeNumber: $typeNumber)';
}
@override
bool operator ==(Object other) {
return identical(this, other) ||
(other.runtimeType == runtimeType &&
other is _$MealCommentModelImpl &&
(identical(other.comment, comment) || other.comment == comment) &&
(identical(other.typeNumber, typeNumber) ||
other.typeNumber == typeNumber));
}
@JsonKey(includeFromJson: false, includeToJson: false)
@override
int get hashCode => Object.hash(runtimeType, comment, typeNumber);
/// Create a copy of MealCommentModel
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
@override
@pragma('vm:prefer-inline')
_$$MealCommentModelImplCopyWith<_$MealCommentModelImpl> get copyWith =>
__$$MealCommentModelImplCopyWithImpl<_$MealCommentModelImpl>(
this, _$identity);
@override
Map<String, dynamic> toJson() {
return _$$MealCommentModelImplToJson(
this,
);
}
}
abstract class _MealCommentModel implements MealCommentModel {
factory _MealCommentModel(
{required final String comment,
@JsonKey(name: 'type_no') required final int typeNumber}) =
_$MealCommentModelImpl;
factory _MealCommentModel.fromJson(Map<String, dynamic> json) =
_$MealCommentModelImpl.fromJson;
@override
String get comment;
@override
@JsonKey(name: 'type_no')
int get typeNumber;
/// Create a copy of MealCommentModel
/// with the given fields replaced by the non-null parameter values.
@override
@JsonKey(includeFromJson: false, includeToJson: false)
_$$MealCommentModelImplCopyWith<_$MealCommentModelImpl> get copyWith =>
throw _privateConstructorUsedError;
}