Dr-Blank.Vaani/lib/settings/models/authenticated_user.freezed.dart
2024-09-06 15:10:00 -04:00

268 lines
8.8 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 'authenticated_user.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');
AuthenticatedUser _$AuthenticatedUserFromJson(Map<String, dynamic> json) {
return _AuthenticatedUser.fromJson(json);
}
/// @nodoc
mixin _$AuthenticatedUser {
AudiobookShelfServer get server => throw _privateConstructorUsedError;
String get authToken => throw _privateConstructorUsedError;
String? get id => throw _privateConstructorUsedError;
String? get username => throw _privateConstructorUsedError;
String? get password => throw _privateConstructorUsedError;
/// Serializes this AuthenticatedUser to a JSON map.
Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
$AuthenticatedUserCopyWith<AuthenticatedUser> get copyWith =>
throw _privateConstructorUsedError;
}
/// @nodoc
abstract class $AuthenticatedUserCopyWith<$Res> {
factory $AuthenticatedUserCopyWith(
AuthenticatedUser value, $Res Function(AuthenticatedUser) then) =
_$AuthenticatedUserCopyWithImpl<$Res, AuthenticatedUser>;
@useResult
$Res call(
{AudiobookShelfServer server,
String authToken,
String? id,
String? username,
String? password});
$AudiobookShelfServerCopyWith<$Res> get server;
}
/// @nodoc
class _$AuthenticatedUserCopyWithImpl<$Res, $Val extends AuthenticatedUser>
implements $AuthenticatedUserCopyWith<$Res> {
_$AuthenticatedUserCopyWithImpl(this._value, this._then);
// ignore: unused_field
final $Val _value;
// ignore: unused_field
final $Res Function($Val) _then;
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? server = null,
Object? authToken = null,
Object? id = freezed,
Object? username = freezed,
Object? password = freezed,
}) {
return _then(_value.copyWith(
server: null == server
? _value.server
: server // ignore: cast_nullable_to_non_nullable
as AudiobookShelfServer,
authToken: null == authToken
? _value.authToken
: authToken // ignore: cast_nullable_to_non_nullable
as String,
id: freezed == id
? _value.id
: id // ignore: cast_nullable_to_non_nullable
as String?,
username: freezed == username
? _value.username
: username // ignore: cast_nullable_to_non_nullable
as String?,
password: freezed == password
? _value.password
: password // ignore: cast_nullable_to_non_nullable
as String?,
) as $Val);
}
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@override
@pragma('vm:prefer-inline')
$AudiobookShelfServerCopyWith<$Res> get server {
return $AudiobookShelfServerCopyWith<$Res>(_value.server, (value) {
return _then(_value.copyWith(server: value) as $Val);
});
}
}
/// @nodoc
abstract class _$$AuthenticatedUserImplCopyWith<$Res>
implements $AuthenticatedUserCopyWith<$Res> {
factory _$$AuthenticatedUserImplCopyWith(_$AuthenticatedUserImpl value,
$Res Function(_$AuthenticatedUserImpl) then) =
__$$AuthenticatedUserImplCopyWithImpl<$Res>;
@override
@useResult
$Res call(
{AudiobookShelfServer server,
String authToken,
String? id,
String? username,
String? password});
@override
$AudiobookShelfServerCopyWith<$Res> get server;
}
/// @nodoc
class __$$AuthenticatedUserImplCopyWithImpl<$Res>
extends _$AuthenticatedUserCopyWithImpl<$Res, _$AuthenticatedUserImpl>
implements _$$AuthenticatedUserImplCopyWith<$Res> {
__$$AuthenticatedUserImplCopyWithImpl(_$AuthenticatedUserImpl _value,
$Res Function(_$AuthenticatedUserImpl) _then)
: super(_value, _then);
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@pragma('vm:prefer-inline')
@override
$Res call({
Object? server = null,
Object? authToken = null,
Object? id = freezed,
Object? username = freezed,
Object? password = freezed,
}) {
return _then(_$AuthenticatedUserImpl(
server: null == server
? _value.server
: server // ignore: cast_nullable_to_non_nullable
as AudiobookShelfServer,
authToken: null == authToken
? _value.authToken
: authToken // ignore: cast_nullable_to_non_nullable
as String,
id: freezed == id
? _value.id
: id // ignore: cast_nullable_to_non_nullable
as String?,
username: freezed == username
? _value.username
: username // ignore: cast_nullable_to_non_nullable
as String?,
password: freezed == password
? _value.password
: password // ignore: cast_nullable_to_non_nullable
as String?,
));
}
}
/// @nodoc
@JsonSerializable()
class _$AuthenticatedUserImpl implements _AuthenticatedUser {
const _$AuthenticatedUserImpl(
{required this.server,
required this.authToken,
this.id,
this.username,
this.password});
factory _$AuthenticatedUserImpl.fromJson(Map<String, dynamic> json) =>
_$$AuthenticatedUserImplFromJson(json);
@override
final AudiobookShelfServer server;
@override
final String authToken;
@override
final String? id;
@override
final String? username;
@override
final String? password;
@override
String toString() {
return 'AuthenticatedUser(server: $server, authToken: $authToken, id: $id, username: $username, password: $password)';
}
@override
bool operator ==(Object other) {
return identical(this, other) ||
(other.runtimeType == runtimeType &&
other is _$AuthenticatedUserImpl &&
(identical(other.server, server) || other.server == server) &&
(identical(other.authToken, authToken) ||
other.authToken == authToken) &&
(identical(other.id, id) || other.id == id) &&
(identical(other.username, username) ||
other.username == username) &&
(identical(other.password, password) ||
other.password == password));
}
@JsonKey(includeFromJson: false, includeToJson: false)
@override
int get hashCode =>
Object.hash(runtimeType, server, authToken, id, username, password);
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@JsonKey(includeFromJson: false, includeToJson: false)
@override
@pragma('vm:prefer-inline')
_$$AuthenticatedUserImplCopyWith<_$AuthenticatedUserImpl> get copyWith =>
__$$AuthenticatedUserImplCopyWithImpl<_$AuthenticatedUserImpl>(
this, _$identity);
@override
Map<String, dynamic> toJson() {
return _$$AuthenticatedUserImplToJson(
this,
);
}
}
abstract class _AuthenticatedUser implements AuthenticatedUser {
const factory _AuthenticatedUser(
{required final AudiobookShelfServer server,
required final String authToken,
final String? id,
final String? username,
final String? password}) = _$AuthenticatedUserImpl;
factory _AuthenticatedUser.fromJson(Map<String, dynamic> json) =
_$AuthenticatedUserImpl.fromJson;
@override
AudiobookShelfServer get server;
@override
String get authToken;
@override
String? get id;
@override
String? get username;
@override
String? get password;
/// Create a copy of AuthenticatedUser
/// with the given fields replaced by the non-null parameter values.
@override
@JsonKey(includeFromJson: false, includeToJson: false)
_$$AuthenticatedUserImplCopyWith<_$AuthenticatedUserImpl> get copyWith =>
throw _privateConstructorUsedError;
}