2025-11-03 16:24:11 +07:00
// 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 ' analytic.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. \n Please check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models ' ,
) ;
/// @nodoc
mixin _ $DashboardAnalytic {
String get organizationId = > throw _privateConstructorUsedError ;
String get outletId = > throw _privateConstructorUsedError ;
String get dateFrom = > throw _privateConstructorUsedError ;
String get dateTo = > throw _privateConstructorUsedError ;
DashboardOverview get overview = > throw _privateConstructorUsedError ;
List < DashboardTopProduct > get topProducts = >
throw _privateConstructorUsedError ;
List < DashboardPaymentMethod > get paymentMethods = >
throw _privateConstructorUsedError ;
List < DashboardRecentSale > get recentSales = >
throw _privateConstructorUsedError ;
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$DashboardAnalyticCopyWith < DashboardAnalytic > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DashboardAnalyticCopyWith < $Res > {
factory $DashboardAnalyticCopyWith (
DashboardAnalytic value ,
$Res Function ( DashboardAnalytic ) then ,
) = _ $DashboardAnalyticCopyWithImpl < $Res , DashboardAnalytic > ;
@ useResult
$Res call ( {
String organizationId ,
String outletId ,
String dateFrom ,
String dateTo ,
DashboardOverview overview ,
List < DashboardTopProduct > topProducts ,
List < DashboardPaymentMethod > paymentMethods ,
List < DashboardRecentSale > recentSales ,
} ) ;
$DashboardOverviewCopyWith < $Res > get overview ;
}
/// @nodoc
class _ $DashboardAnalyticCopyWithImpl < $Res , $Val extends DashboardAnalytic >
implements $DashboardAnalyticCopyWith < $Res > {
_ $DashboardAnalyticCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? organizationId = null ,
Object ? outletId = null ,
Object ? dateFrom = null ,
Object ? dateTo = null ,
Object ? overview = null ,
Object ? topProducts = null ,
Object ? paymentMethods = null ,
Object ? recentSales = null ,
} ) {
return _then (
_value . copyWith (
organizationId: null = = organizationId
? _value . organizationId
: organizationId // ignore: cast_nullable_to_non_nullable
as String ,
outletId: null = = outletId
? _value . outletId
: outletId // ignore: cast_nullable_to_non_nullable
as String ,
dateFrom: null = = dateFrom
? _value . dateFrom
: dateFrom // ignore: cast_nullable_to_non_nullable
as String ,
dateTo: null = = dateTo
? _value . dateTo
: dateTo // ignore: cast_nullable_to_non_nullable
as String ,
overview: null = = overview
? _value . overview
: overview // ignore: cast_nullable_to_non_nullable
as DashboardOverview ,
topProducts: null = = topProducts
? _value . topProducts
: topProducts // ignore: cast_nullable_to_non_nullable
as List < DashboardTopProduct > ,
paymentMethods: null = = paymentMethods
? _value . paymentMethods
: paymentMethods // ignore: cast_nullable_to_non_nullable
as List < DashboardPaymentMethod > ,
recentSales: null = = recentSales
? _value . recentSales
: recentSales // ignore: cast_nullable_to_non_nullable
as List < DashboardRecentSale > ,
)
as $Val ,
) ;
}
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ override
@ pragma ( ' vm:prefer-inline ' )
$DashboardOverviewCopyWith < $Res > get overview {
return $DashboardOverviewCopyWith < $Res > ( _value . overview , ( value ) {
return _then ( _value . copyWith ( overview: value ) as $Val ) ;
} ) ;
}
}
/// @nodoc
abstract class _ $ $DashboardAnalyticImplCopyWith < $Res >
implements $DashboardAnalyticCopyWith < $Res > {
factory _ $ $DashboardAnalyticImplCopyWith (
_ $DashboardAnalyticImpl value ,
$Res Function ( _ $DashboardAnalyticImpl ) then ,
) = __ $ $DashboardAnalyticImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
String organizationId ,
String outletId ,
String dateFrom ,
String dateTo ,
DashboardOverview overview ,
List < DashboardTopProduct > topProducts ,
List < DashboardPaymentMethod > paymentMethods ,
List < DashboardRecentSale > recentSales ,
} ) ;
@ override
$DashboardOverviewCopyWith < $Res > get overview ;
}
/// @nodoc
class __ $ $DashboardAnalyticImplCopyWithImpl < $Res >
extends _ $DashboardAnalyticCopyWithImpl < $Res , _ $DashboardAnalyticImpl >
implements _ $ $DashboardAnalyticImplCopyWith < $Res > {
__ $ $DashboardAnalyticImplCopyWithImpl (
_ $DashboardAnalyticImpl _value ,
$Res Function ( _ $DashboardAnalyticImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? organizationId = null ,
Object ? outletId = null ,
Object ? dateFrom = null ,
Object ? dateTo = null ,
Object ? overview = null ,
Object ? topProducts = null ,
Object ? paymentMethods = null ,
Object ? recentSales = null ,
} ) {
return _then (
_ $DashboardAnalyticImpl (
organizationId: null = = organizationId
? _value . organizationId
: organizationId // ignore: cast_nullable_to_non_nullable
as String ,
outletId: null = = outletId
? _value . outletId
: outletId // ignore: cast_nullable_to_non_nullable
as String ,
dateFrom: null = = dateFrom
? _value . dateFrom
: dateFrom // ignore: cast_nullable_to_non_nullable
as String ,
dateTo: null = = dateTo
? _value . dateTo
: dateTo // ignore: cast_nullable_to_non_nullable
as String ,
overview: null = = overview
? _value . overview
: overview // ignore: cast_nullable_to_non_nullable
as DashboardOverview ,
topProducts: null = = topProducts
? _value . _topProducts
: topProducts // ignore: cast_nullable_to_non_nullable
as List < DashboardTopProduct > ,
paymentMethods: null = = paymentMethods
? _value . _paymentMethods
: paymentMethods // ignore: cast_nullable_to_non_nullable
as List < DashboardPaymentMethod > ,
recentSales: null = = recentSales
? _value . _recentSales
: recentSales // ignore: cast_nullable_to_non_nullable
as List < DashboardRecentSale > ,
) ,
) ;
}
}
/// @nodoc
class _ $DashboardAnalyticImpl implements _DashboardAnalytic {
const _ $DashboardAnalyticImpl ( {
required this . organizationId ,
required this . outletId ,
required this . dateFrom ,
required this . dateTo ,
required this . overview ,
required final List < DashboardTopProduct > topProducts ,
required final List < DashboardPaymentMethod > paymentMethods ,
required final List < DashboardRecentSale > recentSales ,
} ) : _topProducts = topProducts ,
_paymentMethods = paymentMethods ,
_recentSales = recentSales ;
@ override
final String organizationId ;
@ override
final String outletId ;
@ override
final String dateFrom ;
@ override
final String dateTo ;
@ override
final DashboardOverview overview ;
final List < DashboardTopProduct > _topProducts ;
@ override
List < DashboardTopProduct > get topProducts {
if ( _topProducts is EqualUnmodifiableListView ) return _topProducts ;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView ( _topProducts ) ;
}
final List < DashboardPaymentMethod > _paymentMethods ;
@ override
List < DashboardPaymentMethod > get paymentMethods {
if ( _paymentMethods is EqualUnmodifiableListView ) return _paymentMethods ;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView ( _paymentMethods ) ;
}
final List < DashboardRecentSale > _recentSales ;
@ override
List < DashboardRecentSale > get recentSales {
if ( _recentSales is EqualUnmodifiableListView ) return _recentSales ;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView ( _recentSales ) ;
}
@ override
String toString ( ) {
return ' DashboardAnalytic(organizationId: $ organizationId , outletId: $ outletId , dateFrom: $ dateFrom , dateTo: $ dateTo , overview: $ overview , topProducts: $ topProducts , paymentMethods: $ paymentMethods , recentSales: $ recentSales ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DashboardAnalyticImpl & &
( identical ( other . organizationId , organizationId ) | |
other . organizationId = = organizationId ) & &
( identical ( other . outletId , outletId ) | |
other . outletId = = outletId ) & &
( identical ( other . dateFrom , dateFrom ) | |
other . dateFrom = = dateFrom ) & &
( identical ( other . dateTo , dateTo ) | | other . dateTo = = dateTo ) & &
( identical ( other . overview , overview ) | |
other . overview = = overview ) & &
const DeepCollectionEquality ( ) . equals (
other . _topProducts ,
_topProducts ,
) & &
const DeepCollectionEquality ( ) . equals (
other . _paymentMethods ,
_paymentMethods ,
) & &
const DeepCollectionEquality ( ) . equals (
other . _recentSales ,
_recentSales ,
) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
organizationId ,
outletId ,
dateFrom ,
dateTo ,
overview ,
const DeepCollectionEquality ( ) . hash ( _topProducts ) ,
const DeepCollectionEquality ( ) . hash ( _paymentMethods ) ,
const DeepCollectionEquality ( ) . hash ( _recentSales ) ,
) ;
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DashboardAnalyticImplCopyWith < _ $DashboardAnalyticImpl > get copyWith = >
__ $ $DashboardAnalyticImplCopyWithImpl < _ $DashboardAnalyticImpl > (
this ,
_ $identity ,
) ;
}
abstract class _DashboardAnalytic implements DashboardAnalytic {
const factory _DashboardAnalytic ( {
required final String organizationId ,
required final String outletId ,
required final String dateFrom ,
required final String dateTo ,
required final DashboardOverview overview ,
required final List < DashboardTopProduct > topProducts ,
required final List < DashboardPaymentMethod > paymentMethods ,
required final List < DashboardRecentSale > recentSales ,
} ) = _ $DashboardAnalyticImpl ;
@ override
String get organizationId ;
@ override
String get outletId ;
@ override
String get dateFrom ;
@ override
String get dateTo ;
@ override
DashboardOverview get overview ;
@ override
List < DashboardTopProduct > get topProducts ;
@ override
List < DashboardPaymentMethod > get paymentMethods ;
@ override
List < DashboardRecentSale > get recentSales ;
/// Create a copy of DashboardAnalytic
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DashboardAnalyticImplCopyWith < _ $DashboardAnalyticImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $DashboardOverview {
int get totalSales = > throw _privateConstructorUsedError ;
int get totalOrders = > throw _privateConstructorUsedError ;
double get averageOrderValue = > throw _privateConstructorUsedError ;
int get totalCustomers = > throw _privateConstructorUsedError ;
int get voidedOrders = > throw _privateConstructorUsedError ;
int get refundedOrders = > throw _privateConstructorUsedError ;
/// Create a copy of DashboardOverview
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$DashboardOverviewCopyWith < DashboardOverview > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DashboardOverviewCopyWith < $Res > {
factory $DashboardOverviewCopyWith (
DashboardOverview value ,
$Res Function ( DashboardOverview ) then ,
) = _ $DashboardOverviewCopyWithImpl < $Res , DashboardOverview > ;
@ useResult
$Res call ( {
int totalSales ,
int totalOrders ,
double averageOrderValue ,
int totalCustomers ,
int voidedOrders ,
int refundedOrders ,
} ) ;
}
/// @nodoc
class _ $DashboardOverviewCopyWithImpl < $Res , $Val extends DashboardOverview >
implements $DashboardOverviewCopyWith < $Res > {
_ $DashboardOverviewCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of DashboardOverview
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? totalSales = null ,
Object ? totalOrders = null ,
Object ? averageOrderValue = null ,
Object ? totalCustomers = null ,
Object ? voidedOrders = null ,
Object ? refundedOrders = null ,
} ) {
return _then (
_value . copyWith (
totalSales: null = = totalSales
? _value . totalSales
: totalSales // ignore: cast_nullable_to_non_nullable
as int ,
totalOrders: null = = totalOrders
? _value . totalOrders
: totalOrders // ignore: cast_nullable_to_non_nullable
as int ,
averageOrderValue: null = = averageOrderValue
? _value . averageOrderValue
: averageOrderValue // ignore: cast_nullable_to_non_nullable
as double ,
totalCustomers: null = = totalCustomers
? _value . totalCustomers
: totalCustomers // ignore: cast_nullable_to_non_nullable
as int ,
voidedOrders: null = = voidedOrders
? _value . voidedOrders
: voidedOrders // ignore: cast_nullable_to_non_nullable
as int ,
refundedOrders: null = = refundedOrders
? _value . refundedOrders
: refundedOrders // ignore: cast_nullable_to_non_nullable
as int ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $DashboardOverviewImplCopyWith < $Res >
implements $DashboardOverviewCopyWith < $Res > {
factory _ $ $DashboardOverviewImplCopyWith (
_ $DashboardOverviewImpl value ,
$Res Function ( _ $DashboardOverviewImpl ) then ,
) = __ $ $DashboardOverviewImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
int totalSales ,
int totalOrders ,
double averageOrderValue ,
int totalCustomers ,
int voidedOrders ,
int refundedOrders ,
} ) ;
}
/// @nodoc
class __ $ $DashboardOverviewImplCopyWithImpl < $Res >
extends _ $DashboardOverviewCopyWithImpl < $Res , _ $DashboardOverviewImpl >
implements _ $ $DashboardOverviewImplCopyWith < $Res > {
__ $ $DashboardOverviewImplCopyWithImpl (
_ $DashboardOverviewImpl _value ,
$Res Function ( _ $DashboardOverviewImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of DashboardOverview
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? totalSales = null ,
Object ? totalOrders = null ,
Object ? averageOrderValue = null ,
Object ? totalCustomers = null ,
Object ? voidedOrders = null ,
Object ? refundedOrders = null ,
} ) {
return _then (
_ $DashboardOverviewImpl (
totalSales: null = = totalSales
? _value . totalSales
: totalSales // ignore: cast_nullable_to_non_nullable
as int ,
totalOrders: null = = totalOrders
? _value . totalOrders
: totalOrders // ignore: cast_nullable_to_non_nullable
as int ,
averageOrderValue: null = = averageOrderValue
? _value . averageOrderValue
: averageOrderValue // ignore: cast_nullable_to_non_nullable
as double ,
totalCustomers: null = = totalCustomers
? _value . totalCustomers
: totalCustomers // ignore: cast_nullable_to_non_nullable
as int ,
voidedOrders: null = = voidedOrders
? _value . voidedOrders
: voidedOrders // ignore: cast_nullable_to_non_nullable
as int ,
refundedOrders: null = = refundedOrders
? _value . refundedOrders
: refundedOrders // ignore: cast_nullable_to_non_nullable
as int ,
) ,
) ;
}
}
/// @nodoc
class _ $DashboardOverviewImpl implements _DashboardOverview {
const _ $DashboardOverviewImpl ( {
required this . totalSales ,
required this . totalOrders ,
required this . averageOrderValue ,
required this . totalCustomers ,
required this . voidedOrders ,
required this . refundedOrders ,
} ) ;
@ override
final int totalSales ;
@ override
final int totalOrders ;
@ override
final double averageOrderValue ;
@ override
final int totalCustomers ;
@ override
final int voidedOrders ;
@ override
final int refundedOrders ;
@ override
String toString ( ) {
return ' DashboardOverview(totalSales: $ totalSales , totalOrders: $ totalOrders , averageOrderValue: $ averageOrderValue , totalCustomers: $ totalCustomers , voidedOrders: $ voidedOrders , refundedOrders: $ refundedOrders ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DashboardOverviewImpl & &
( identical ( other . totalSales , totalSales ) | |
other . totalSales = = totalSales ) & &
( identical ( other . totalOrders , totalOrders ) | |
other . totalOrders = = totalOrders ) & &
( identical ( other . averageOrderValue , averageOrderValue ) | |
other . averageOrderValue = = averageOrderValue ) & &
( identical ( other . totalCustomers , totalCustomers ) | |
other . totalCustomers = = totalCustomers ) & &
( identical ( other . voidedOrders , voidedOrders ) | |
other . voidedOrders = = voidedOrders ) & &
( identical ( other . refundedOrders , refundedOrders ) | |
other . refundedOrders = = refundedOrders ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
totalSales ,
totalOrders ,
averageOrderValue ,
totalCustomers ,
voidedOrders ,
refundedOrders ,
) ;
/// Create a copy of DashboardOverview
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DashboardOverviewImplCopyWith < _ $DashboardOverviewImpl > get copyWith = >
__ $ $DashboardOverviewImplCopyWithImpl < _ $DashboardOverviewImpl > (
this ,
_ $identity ,
) ;
}
abstract class _DashboardOverview implements DashboardOverview {
const factory _DashboardOverview ( {
required final int totalSales ,
required final int totalOrders ,
required final double averageOrderValue ,
required final int totalCustomers ,
required final int voidedOrders ,
required final int refundedOrders ,
} ) = _ $DashboardOverviewImpl ;
@ override
int get totalSales ;
@ override
int get totalOrders ;
@ override
double get averageOrderValue ;
@ override
int get totalCustomers ;
@ override
int get voidedOrders ;
@ override
int get refundedOrders ;
/// Create a copy of DashboardOverview
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DashboardOverviewImplCopyWith < _ $DashboardOverviewImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $DashboardTopProduct {
String get productId = > throw _privateConstructorUsedError ;
String get productName = > throw _privateConstructorUsedError ;
String get categoryId = > throw _privateConstructorUsedError ;
String get categoryName = > throw _privateConstructorUsedError ;
int get quantitySold = > throw _privateConstructorUsedError ;
int get revenue = > throw _privateConstructorUsedError ;
double get averagePrice = > throw _privateConstructorUsedError ;
int get orderCount = > throw _privateConstructorUsedError ;
/// Create a copy of DashboardTopProduct
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$DashboardTopProductCopyWith < DashboardTopProduct > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DashboardTopProductCopyWith < $Res > {
factory $DashboardTopProductCopyWith (
DashboardTopProduct value ,
$Res Function ( DashboardTopProduct ) then ,
) = _ $DashboardTopProductCopyWithImpl < $Res , DashboardTopProduct > ;
@ useResult
$Res call ( {
String productId ,
String productName ,
String categoryId ,
String categoryName ,
int quantitySold ,
int revenue ,
double averagePrice ,
int orderCount ,
} ) ;
}
/// @nodoc
class _ $DashboardTopProductCopyWithImpl < $Res , $Val extends DashboardTopProduct >
implements $DashboardTopProductCopyWith < $Res > {
_ $DashboardTopProductCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of DashboardTopProduct
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? productId = null ,
Object ? productName = null ,
Object ? categoryId = null ,
Object ? categoryName = null ,
Object ? quantitySold = null ,
Object ? revenue = null ,
Object ? averagePrice = null ,
Object ? orderCount = null ,
} ) {
return _then (
_value . copyWith (
productId: null = = productId
? _value . productId
: productId // ignore: cast_nullable_to_non_nullable
as String ,
productName: null = = productName
? _value . productName
: productName // ignore: cast_nullable_to_non_nullable
as String ,
categoryId: null = = categoryId
? _value . categoryId
: categoryId // ignore: cast_nullable_to_non_nullable
as String ,
categoryName: null = = categoryName
? _value . categoryName
: categoryName // ignore: cast_nullable_to_non_nullable
as String ,
quantitySold: null = = quantitySold
? _value . quantitySold
: quantitySold // ignore: cast_nullable_to_non_nullable
as int ,
revenue: null = = revenue
? _value . revenue
: revenue // ignore: cast_nullable_to_non_nullable
as int ,
averagePrice: null = = averagePrice
? _value . averagePrice
: averagePrice // ignore: cast_nullable_to_non_nullable
as double ,
orderCount: null = = orderCount
? _value . orderCount
: orderCount // ignore: cast_nullable_to_non_nullable
as int ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $DashboardTopProductImplCopyWith < $Res >
implements $DashboardTopProductCopyWith < $Res > {
factory _ $ $DashboardTopProductImplCopyWith (
_ $DashboardTopProductImpl value ,
$Res Function ( _ $DashboardTopProductImpl ) then ,
) = __ $ $DashboardTopProductImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
String productId ,
String productName ,
String categoryId ,
String categoryName ,
int quantitySold ,
int revenue ,
double averagePrice ,
int orderCount ,
} ) ;
}
/// @nodoc
class __ $ $DashboardTopProductImplCopyWithImpl < $Res >
extends _ $DashboardTopProductCopyWithImpl < $Res , _ $DashboardTopProductImpl >
implements _ $ $DashboardTopProductImplCopyWith < $Res > {
__ $ $DashboardTopProductImplCopyWithImpl (
_ $DashboardTopProductImpl _value ,
$Res Function ( _ $DashboardTopProductImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of DashboardTopProduct
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? productId = null ,
Object ? productName = null ,
Object ? categoryId = null ,
Object ? categoryName = null ,
Object ? quantitySold = null ,
Object ? revenue = null ,
Object ? averagePrice = null ,
Object ? orderCount = null ,
} ) {
return _then (
_ $DashboardTopProductImpl (
productId: null = = productId
? _value . productId
: productId // ignore: cast_nullable_to_non_nullable
as String ,
productName: null = = productName
? _value . productName
: productName // ignore: cast_nullable_to_non_nullable
as String ,
categoryId: null = = categoryId
? _value . categoryId
: categoryId // ignore: cast_nullable_to_non_nullable
as String ,
categoryName: null = = categoryName
? _value . categoryName
: categoryName // ignore: cast_nullable_to_non_nullable
as String ,
quantitySold: null = = quantitySold
? _value . quantitySold
: quantitySold // ignore: cast_nullable_to_non_nullable
as int ,
revenue: null = = revenue
? _value . revenue
: revenue // ignore: cast_nullable_to_non_nullable
as int ,
averagePrice: null = = averagePrice
? _value . averagePrice
: averagePrice // ignore: cast_nullable_to_non_nullable
as double ,
orderCount: null = = orderCount
? _value . orderCount
: orderCount // ignore: cast_nullable_to_non_nullable
as int ,
) ,
) ;
}
}
/// @nodoc
class _ $DashboardTopProductImpl implements _DashboardTopProduct {
const _ $DashboardTopProductImpl ( {
required this . productId ,
required this . productName ,
required this . categoryId ,
required this . categoryName ,
required this . quantitySold ,
required this . revenue ,
required this . averagePrice ,
required this . orderCount ,
} ) ;
@ override
final String productId ;
@ override
final String productName ;
@ override
final String categoryId ;
@ override
final String categoryName ;
@ override
final int quantitySold ;
@ override
final int revenue ;
@ override
final double averagePrice ;
@ override
final int orderCount ;
@ override
String toString ( ) {
return ' DashboardTopProduct(productId: $ productId , productName: $ productName , categoryId: $ categoryId , categoryName: $ categoryName , quantitySold: $ quantitySold , revenue: $ revenue , averagePrice: $ averagePrice , orderCount: $ orderCount ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DashboardTopProductImpl & &
( identical ( other . productId , productId ) | |
other . productId = = productId ) & &
( identical ( other . productName , productName ) | |
other . productName = = productName ) & &
( identical ( other . categoryId , categoryId ) | |
other . categoryId = = categoryId ) & &
( identical ( other . categoryName , categoryName ) | |
other . categoryName = = categoryName ) & &
( identical ( other . quantitySold , quantitySold ) | |
other . quantitySold = = quantitySold ) & &
( identical ( other . revenue , revenue ) | | other . revenue = = revenue ) & &
( identical ( other . averagePrice , averagePrice ) | |
other . averagePrice = = averagePrice ) & &
( identical ( other . orderCount , orderCount ) | |
other . orderCount = = orderCount ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
productId ,
productName ,
categoryId ,
categoryName ,
quantitySold ,
revenue ,
averagePrice ,
orderCount ,
) ;
/// Create a copy of DashboardTopProduct
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DashboardTopProductImplCopyWith < _ $DashboardTopProductImpl > get copyWith = >
__ $ $DashboardTopProductImplCopyWithImpl < _ $DashboardTopProductImpl > (
this ,
_ $identity ,
) ;
}
abstract class _DashboardTopProduct implements DashboardTopProduct {
const factory _DashboardTopProduct ( {
required final String productId ,
required final String productName ,
required final String categoryId ,
required final String categoryName ,
required final int quantitySold ,
required final int revenue ,
required final double averagePrice ,
required final int orderCount ,
} ) = _ $DashboardTopProductImpl ;
@ override
String get productId ;
@ override
String get productName ;
@ override
String get categoryId ;
@ override
String get categoryName ;
@ override
int get quantitySold ;
@ override
int get revenue ;
@ override
double get averagePrice ;
@ override
int get orderCount ;
/// Create a copy of DashboardTopProduct
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DashboardTopProductImplCopyWith < _ $DashboardTopProductImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $DashboardPaymentMethod {
String get paymentMethodId = > throw _privateConstructorUsedError ;
String get paymentMethodName = > throw _privateConstructorUsedError ;
String get paymentMethodType = > throw _privateConstructorUsedError ;
int get totalAmount = > throw _privateConstructorUsedError ;
int get orderCount = > throw _privateConstructorUsedError ;
int get paymentCount = > throw _privateConstructorUsedError ;
double get percentage = > throw _privateConstructorUsedError ;
/// Create a copy of DashboardPaymentMethod
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$DashboardPaymentMethodCopyWith < DashboardPaymentMethod > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DashboardPaymentMethodCopyWith < $Res > {
factory $DashboardPaymentMethodCopyWith (
DashboardPaymentMethod value ,
$Res Function ( DashboardPaymentMethod ) then ,
) = _ $DashboardPaymentMethodCopyWithImpl < $Res , DashboardPaymentMethod > ;
@ useResult
$Res call ( {
String paymentMethodId ,
String paymentMethodName ,
String paymentMethodType ,
int totalAmount ,
int orderCount ,
int paymentCount ,
double percentage ,
} ) ;
}
/// @nodoc
class _ $DashboardPaymentMethodCopyWithImpl <
$Res ,
$Val extends DashboardPaymentMethod
>
implements $DashboardPaymentMethodCopyWith < $Res > {
_ $DashboardPaymentMethodCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of DashboardPaymentMethod
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? paymentMethodId = null ,
Object ? paymentMethodName = null ,
Object ? paymentMethodType = null ,
Object ? totalAmount = null ,
Object ? orderCount = null ,
Object ? paymentCount = null ,
Object ? percentage = null ,
} ) {
return _then (
_value . copyWith (
paymentMethodId: null = = paymentMethodId
? _value . paymentMethodId
: paymentMethodId // ignore: cast_nullable_to_non_nullable
as String ,
paymentMethodName: null = = paymentMethodName
? _value . paymentMethodName
: paymentMethodName // ignore: cast_nullable_to_non_nullable
as String ,
paymentMethodType: null = = paymentMethodType
? _value . paymentMethodType
: paymentMethodType // ignore: cast_nullable_to_non_nullable
as String ,
totalAmount: null = = totalAmount
? _value . totalAmount
: totalAmount // ignore: cast_nullable_to_non_nullable
as int ,
orderCount: null = = orderCount
? _value . orderCount
: orderCount // ignore: cast_nullable_to_non_nullable
as int ,
paymentCount: null = = paymentCount
? _value . paymentCount
: paymentCount // ignore: cast_nullable_to_non_nullable
as int ,
percentage: null = = percentage
? _value . percentage
: percentage // ignore: cast_nullable_to_non_nullable
as double ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $DashboardPaymentMethodImplCopyWith < $Res >
implements $DashboardPaymentMethodCopyWith < $Res > {
factory _ $ $DashboardPaymentMethodImplCopyWith (
_ $DashboardPaymentMethodImpl value ,
$Res Function ( _ $DashboardPaymentMethodImpl ) then ,
) = __ $ $DashboardPaymentMethodImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
String paymentMethodId ,
String paymentMethodName ,
String paymentMethodType ,
int totalAmount ,
int orderCount ,
int paymentCount ,
double percentage ,
} ) ;
}
/// @nodoc
class __ $ $DashboardPaymentMethodImplCopyWithImpl < $Res >
extends
_ $DashboardPaymentMethodCopyWithImpl < $Res , _ $DashboardPaymentMethodImpl >
implements _ $ $DashboardPaymentMethodImplCopyWith < $Res > {
__ $ $DashboardPaymentMethodImplCopyWithImpl (
_ $DashboardPaymentMethodImpl _value ,
$Res Function ( _ $DashboardPaymentMethodImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of DashboardPaymentMethod
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? paymentMethodId = null ,
Object ? paymentMethodName = null ,
Object ? paymentMethodType = null ,
Object ? totalAmount = null ,
Object ? orderCount = null ,
Object ? paymentCount = null ,
Object ? percentage = null ,
} ) {
return _then (
_ $DashboardPaymentMethodImpl (
paymentMethodId: null = = paymentMethodId
? _value . paymentMethodId
: paymentMethodId // ignore: cast_nullable_to_non_nullable
as String ,
paymentMethodName: null = = paymentMethodName
? _value . paymentMethodName
: paymentMethodName // ignore: cast_nullable_to_non_nullable
as String ,
paymentMethodType: null = = paymentMethodType
? _value . paymentMethodType
: paymentMethodType // ignore: cast_nullable_to_non_nullable
as String ,
totalAmount: null = = totalAmount
? _value . totalAmount
: totalAmount // ignore: cast_nullable_to_non_nullable
as int ,
orderCount: null = = orderCount
? _value . orderCount
: orderCount // ignore: cast_nullable_to_non_nullable
as int ,
paymentCount: null = = paymentCount
? _value . paymentCount
: paymentCount // ignore: cast_nullable_to_non_nullable
as int ,
percentage: null = = percentage
? _value . percentage
: percentage // ignore: cast_nullable_to_non_nullable
as double ,
) ,
) ;
}
}
/// @nodoc
class _ $DashboardPaymentMethodImpl implements _DashboardPaymentMethod {
const _ $DashboardPaymentMethodImpl ( {
required this . paymentMethodId ,
required this . paymentMethodName ,
required this . paymentMethodType ,
required this . totalAmount ,
required this . orderCount ,
required this . paymentCount ,
required this . percentage ,
} ) ;
@ override
final String paymentMethodId ;
@ override
final String paymentMethodName ;
@ override
final String paymentMethodType ;
@ override
final int totalAmount ;
@ override
final int orderCount ;
@ override
final int paymentCount ;
@ override
final double percentage ;
@ override
String toString ( ) {
return ' DashboardPaymentMethod(paymentMethodId: $ paymentMethodId , paymentMethodName: $ paymentMethodName , paymentMethodType: $ paymentMethodType , totalAmount: $ totalAmount , orderCount: $ orderCount , paymentCount: $ paymentCount , percentage: $ percentage ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DashboardPaymentMethodImpl & &
( identical ( other . paymentMethodId , paymentMethodId ) | |
other . paymentMethodId = = paymentMethodId ) & &
( identical ( other . paymentMethodName , paymentMethodName ) | |
other . paymentMethodName = = paymentMethodName ) & &
( identical ( other . paymentMethodType , paymentMethodType ) | |
other . paymentMethodType = = paymentMethodType ) & &
( identical ( other . totalAmount , totalAmount ) | |
other . totalAmount = = totalAmount ) & &
( identical ( other . orderCount , orderCount ) | |
other . orderCount = = orderCount ) & &
( identical ( other . paymentCount , paymentCount ) | |
other . paymentCount = = paymentCount ) & &
( identical ( other . percentage , percentage ) | |
other . percentage = = percentage ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
paymentMethodId ,
paymentMethodName ,
paymentMethodType ,
totalAmount ,
orderCount ,
paymentCount ,
percentage ,
) ;
/// Create a copy of DashboardPaymentMethod
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DashboardPaymentMethodImplCopyWith < _ $DashboardPaymentMethodImpl >
get copyWith = >
__ $ $DashboardPaymentMethodImplCopyWithImpl < _ $DashboardPaymentMethodImpl > (
this ,
_ $identity ,
) ;
}
abstract class _DashboardPaymentMethod implements DashboardPaymentMethod {
const factory _DashboardPaymentMethod ( {
required final String paymentMethodId ,
required final String paymentMethodName ,
required final String paymentMethodType ,
required final int totalAmount ,
required final int orderCount ,
required final int paymentCount ,
required final double percentage ,
} ) = _ $DashboardPaymentMethodImpl ;
@ override
String get paymentMethodId ;
@ override
String get paymentMethodName ;
@ override
String get paymentMethodType ;
@ override
int get totalAmount ;
@ override
int get orderCount ;
@ override
int get paymentCount ;
@ override
double get percentage ;
/// Create a copy of DashboardPaymentMethod
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DashboardPaymentMethodImplCopyWith < _ $DashboardPaymentMethodImpl >
get copyWith = > throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $DashboardRecentSale {
String get date = > throw _privateConstructorUsedError ;
int get sales = > throw _privateConstructorUsedError ;
int get orders = > throw _privateConstructorUsedError ;
int get items = > throw _privateConstructorUsedError ;
int get tax = > throw _privateConstructorUsedError ;
int get discount = > throw _privateConstructorUsedError ;
int get netSales = > throw _privateConstructorUsedError ;
/// Create a copy of DashboardRecentSale
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$DashboardRecentSaleCopyWith < DashboardRecentSale > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $DashboardRecentSaleCopyWith < $Res > {
factory $DashboardRecentSaleCopyWith (
DashboardRecentSale value ,
$Res Function ( DashboardRecentSale ) then ,
) = _ $DashboardRecentSaleCopyWithImpl < $Res , DashboardRecentSale > ;
@ useResult
$Res call ( {
String date ,
int sales ,
int orders ,
int items ,
int tax ,
int discount ,
int netSales ,
} ) ;
}
/// @nodoc
class _ $DashboardRecentSaleCopyWithImpl < $Res , $Val extends DashboardRecentSale >
implements $DashboardRecentSaleCopyWith < $Res > {
_ $DashboardRecentSaleCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of DashboardRecentSale
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? date = null ,
Object ? sales = null ,
Object ? orders = null ,
Object ? items = null ,
Object ? tax = null ,
Object ? discount = null ,
Object ? netSales = null ,
} ) {
return _then (
_value . copyWith (
date: null = = date
? _value . date
: date // ignore: cast_nullable_to_non_nullable
as String ,
sales: null = = sales
? _value . sales
: sales // ignore: cast_nullable_to_non_nullable
as int ,
orders: null = = orders
? _value . orders
: orders // ignore: cast_nullable_to_non_nullable
as int ,
items: null = = items
? _value . items
: items // ignore: cast_nullable_to_non_nullable
as int ,
tax: null = = tax
? _value . tax
: tax // ignore: cast_nullable_to_non_nullable
as int ,
discount: null = = discount
? _value . discount
: discount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $DashboardRecentSaleImplCopyWith < $Res >
implements $DashboardRecentSaleCopyWith < $Res > {
factory _ $ $DashboardRecentSaleImplCopyWith (
_ $DashboardRecentSaleImpl value ,
$Res Function ( _ $DashboardRecentSaleImpl ) then ,
) = __ $ $DashboardRecentSaleImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
String date ,
int sales ,
int orders ,
int items ,
int tax ,
int discount ,
int netSales ,
} ) ;
}
/// @nodoc
class __ $ $DashboardRecentSaleImplCopyWithImpl < $Res >
extends _ $DashboardRecentSaleCopyWithImpl < $Res , _ $DashboardRecentSaleImpl >
implements _ $ $DashboardRecentSaleImplCopyWith < $Res > {
__ $ $DashboardRecentSaleImplCopyWithImpl (
_ $DashboardRecentSaleImpl _value ,
$Res Function ( _ $DashboardRecentSaleImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of DashboardRecentSale
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? date = null ,
Object ? sales = null ,
Object ? orders = null ,
Object ? items = null ,
Object ? tax = null ,
Object ? discount = null ,
Object ? netSales = null ,
} ) {
return _then (
_ $DashboardRecentSaleImpl (
date: null = = date
? _value . date
: date // ignore: cast_nullable_to_non_nullable
as String ,
sales: null = = sales
? _value . sales
: sales // ignore: cast_nullable_to_non_nullable
as int ,
orders: null = = orders
? _value . orders
: orders // ignore: cast_nullable_to_non_nullable
as int ,
items: null = = items
? _value . items
: items // ignore: cast_nullable_to_non_nullable
as int ,
tax: null = = tax
? _value . tax
: tax // ignore: cast_nullable_to_non_nullable
as int ,
discount: null = = discount
? _value . discount
: discount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
) ,
) ;
}
}
/// @nodoc
class _ $DashboardRecentSaleImpl implements _DashboardRecentSale {
const _ $DashboardRecentSaleImpl ( {
required this . date ,
required this . sales ,
required this . orders ,
required this . items ,
required this . tax ,
required this . discount ,
required this . netSales ,
} ) ;
@ override
final String date ;
@ override
final int sales ;
@ override
final int orders ;
@ override
final int items ;
@ override
final int tax ;
@ override
final int discount ;
@ override
final int netSales ;
@ override
String toString ( ) {
return ' DashboardRecentSale(date: $ date , sales: $ sales , orders: $ orders , items: $ items , tax: $ tax , discount: $ discount , netSales: $ netSales ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DashboardRecentSaleImpl & &
( identical ( other . date , date ) | | other . date = = date ) & &
( identical ( other . sales , sales ) | | other . sales = = sales ) & &
( identical ( other . orders , orders ) | | other . orders = = orders ) & &
( identical ( other . items , items ) | | other . items = = items ) & &
( identical ( other . tax , tax ) | | other . tax = = tax ) & &
( identical ( other . discount , discount ) | |
other . discount = = discount ) & &
( identical ( other . netSales , netSales ) | |
other . netSales = = netSales ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
date ,
sales ,
orders ,
items ,
tax ,
discount ,
netSales ,
) ;
/// Create a copy of DashboardRecentSale
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DashboardRecentSaleImplCopyWith < _ $DashboardRecentSaleImpl > get copyWith = >
__ $ $DashboardRecentSaleImplCopyWithImpl < _ $DashboardRecentSaleImpl > (
this ,
_ $identity ,
) ;
}
abstract class _DashboardRecentSale implements DashboardRecentSale {
const factory _DashboardRecentSale ( {
required final String date ,
required final int sales ,
required final int orders ,
required final int items ,
required final int tax ,
required final int discount ,
required final int netSales ,
} ) = _ $DashboardRecentSaleImpl ;
@ override
String get date ;
@ override
int get sales ;
@ override
int get orders ;
@ override
int get items ;
@ override
int get tax ;
@ override
int get discount ;
@ override
int get netSales ;
/// Create a copy of DashboardRecentSale
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DashboardRecentSaleImplCopyWith < _ $DashboardRecentSaleImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
2025-11-03 17:18:29 +07:00
/// @nodoc
mixin _ $SalesAnalytic {
String get organizationId = > throw _privateConstructorUsedError ;
String get outletId = > throw _privateConstructorUsedError ;
DateTime get dateFrom = > throw _privateConstructorUsedError ;
DateTime get dateTo = > throw _privateConstructorUsedError ;
String get groupBy = > throw _privateConstructorUsedError ;
SalesSummary get summary = > throw _privateConstructorUsedError ;
List < SalesAnalyticItem > get data = > throw _privateConstructorUsedError ;
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$SalesAnalyticCopyWith < SalesAnalytic > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $SalesAnalyticCopyWith < $Res > {
factory $SalesAnalyticCopyWith (
SalesAnalytic value ,
$Res Function ( SalesAnalytic ) then ,
) = _ $SalesAnalyticCopyWithImpl < $Res , SalesAnalytic > ;
@ useResult
$Res call ( {
String organizationId ,
String outletId ,
DateTime dateFrom ,
DateTime dateTo ,
String groupBy ,
SalesSummary summary ,
List < SalesAnalyticItem > data ,
} ) ;
$SalesSummaryCopyWith < $Res > get summary ;
}
/// @nodoc
class _ $SalesAnalyticCopyWithImpl < $Res , $Val extends SalesAnalytic >
implements $SalesAnalyticCopyWith < $Res > {
_ $SalesAnalyticCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? organizationId = null ,
Object ? outletId = null ,
Object ? dateFrom = null ,
Object ? dateTo = null ,
Object ? groupBy = null ,
Object ? summary = null ,
Object ? data = null ,
} ) {
return _then (
_value . copyWith (
organizationId: null = = organizationId
? _value . organizationId
: organizationId // ignore: cast_nullable_to_non_nullable
as String ,
outletId: null = = outletId
? _value . outletId
: outletId // ignore: cast_nullable_to_non_nullable
as String ,
dateFrom: null = = dateFrom
? _value . dateFrom
: dateFrom // ignore: cast_nullable_to_non_nullable
as DateTime ,
dateTo: null = = dateTo
? _value . dateTo
: dateTo // ignore: cast_nullable_to_non_nullable
as DateTime ,
groupBy: null = = groupBy
? _value . groupBy
: groupBy // ignore: cast_nullable_to_non_nullable
as String ,
summary: null = = summary
? _value . summary
: summary // ignore: cast_nullable_to_non_nullable
as SalesSummary ,
data: null = = data
? _value . data
: data // ignore: cast_nullable_to_non_nullable
as List < SalesAnalyticItem > ,
)
as $Val ,
) ;
}
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ override
@ pragma ( ' vm:prefer-inline ' )
$SalesSummaryCopyWith < $Res > get summary {
return $SalesSummaryCopyWith < $Res > ( _value . summary , ( value ) {
return _then ( _value . copyWith ( summary: value ) as $Val ) ;
} ) ;
}
}
/// @nodoc
abstract class _ $ $SalesAnalyticImplCopyWith < $Res >
implements $SalesAnalyticCopyWith < $Res > {
factory _ $ $SalesAnalyticImplCopyWith (
_ $SalesAnalyticImpl value ,
$Res Function ( _ $SalesAnalyticImpl ) then ,
) = __ $ $SalesAnalyticImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
String organizationId ,
String outletId ,
DateTime dateFrom ,
DateTime dateTo ,
String groupBy ,
SalesSummary summary ,
List < SalesAnalyticItem > data ,
} ) ;
@ override
$SalesSummaryCopyWith < $Res > get summary ;
}
/// @nodoc
class __ $ $SalesAnalyticImplCopyWithImpl < $Res >
extends _ $SalesAnalyticCopyWithImpl < $Res , _ $SalesAnalyticImpl >
implements _ $ $SalesAnalyticImplCopyWith < $Res > {
__ $ $SalesAnalyticImplCopyWithImpl (
_ $SalesAnalyticImpl _value ,
$Res Function ( _ $SalesAnalyticImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? organizationId = null ,
Object ? outletId = null ,
Object ? dateFrom = null ,
Object ? dateTo = null ,
Object ? groupBy = null ,
Object ? summary = null ,
Object ? data = null ,
} ) {
return _then (
_ $SalesAnalyticImpl (
organizationId: null = = organizationId
? _value . organizationId
: organizationId // ignore: cast_nullable_to_non_nullable
as String ,
outletId: null = = outletId
? _value . outletId
: outletId // ignore: cast_nullable_to_non_nullable
as String ,
dateFrom: null = = dateFrom
? _value . dateFrom
: dateFrom // ignore: cast_nullable_to_non_nullable
as DateTime ,
dateTo: null = = dateTo
? _value . dateTo
: dateTo // ignore: cast_nullable_to_non_nullable
as DateTime ,
groupBy: null = = groupBy
? _value . groupBy
: groupBy // ignore: cast_nullable_to_non_nullable
as String ,
summary: null = = summary
? _value . summary
: summary // ignore: cast_nullable_to_non_nullable
as SalesSummary ,
data: null = = data
? _value . _data
: data // ignore: cast_nullable_to_non_nullable
as List < SalesAnalyticItem > ,
) ,
) ;
}
}
/// @nodoc
class _ $SalesAnalyticImpl extends _SalesAnalytic {
const _ $SalesAnalyticImpl ( {
required this . organizationId ,
required this . outletId ,
required this . dateFrom ,
required this . dateTo ,
required this . groupBy ,
required this . summary ,
required final List < SalesAnalyticItem > data ,
} ) : _data = data ,
super . _ ( ) ;
@ override
final String organizationId ;
@ override
final String outletId ;
@ override
final DateTime dateFrom ;
@ override
final DateTime dateTo ;
@ override
final String groupBy ;
@ override
final SalesSummary summary ;
final List < SalesAnalyticItem > _data ;
@ override
List < SalesAnalyticItem > get data {
if ( _data is EqualUnmodifiableListView ) return _data ;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView ( _data ) ;
}
@ override
String toString ( ) {
return ' SalesAnalytic(organizationId: $ organizationId , outletId: $ outletId , dateFrom: $ dateFrom , dateTo: $ dateTo , groupBy: $ groupBy , summary: $ summary , data: $ data ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $SalesAnalyticImpl & &
( identical ( other . organizationId , organizationId ) | |
other . organizationId = = organizationId ) & &
( identical ( other . outletId , outletId ) | |
other . outletId = = outletId ) & &
( identical ( other . dateFrom , dateFrom ) | |
other . dateFrom = = dateFrom ) & &
( identical ( other . dateTo , dateTo ) | | other . dateTo = = dateTo ) & &
( identical ( other . groupBy , groupBy ) | | other . groupBy = = groupBy ) & &
( identical ( other . summary , summary ) | | other . summary = = summary ) & &
const DeepCollectionEquality ( ) . equals ( other . _data , _data ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
organizationId ,
outletId ,
dateFrom ,
dateTo ,
groupBy ,
summary ,
const DeepCollectionEquality ( ) . hash ( _data ) ,
) ;
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $SalesAnalyticImplCopyWith < _ $SalesAnalyticImpl > get copyWith = >
__ $ $SalesAnalyticImplCopyWithImpl < _ $SalesAnalyticImpl > ( this , _ $identity ) ;
}
abstract class _SalesAnalytic extends SalesAnalytic {
const factory _SalesAnalytic ( {
required final String organizationId ,
required final String outletId ,
required final DateTime dateFrom ,
required final DateTime dateTo ,
required final String groupBy ,
required final SalesSummary summary ,
required final List < SalesAnalyticItem > data ,
} ) = _ $SalesAnalyticImpl ;
const _SalesAnalytic . _ ( ) : super . _ ( ) ;
@ override
String get organizationId ;
@ override
String get outletId ;
@ override
DateTime get dateFrom ;
@ override
DateTime get dateTo ;
@ override
String get groupBy ;
@ override
SalesSummary get summary ;
@ override
List < SalesAnalyticItem > get data ;
/// Create a copy of SalesAnalytic
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $SalesAnalyticImplCopyWith < _ $SalesAnalyticImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $SalesSummary {
int get totalSales = > throw _privateConstructorUsedError ;
int get totalOrders = > throw _privateConstructorUsedError ;
int get totalItems = > throw _privateConstructorUsedError ;
double get averageOrderValue = > throw _privateConstructorUsedError ;
int get totalTax = > throw _privateConstructorUsedError ;
int get totalDiscount = > throw _privateConstructorUsedError ;
int get netSales = > throw _privateConstructorUsedError ;
/// Create a copy of SalesSummary
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$SalesSummaryCopyWith < SalesSummary > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $SalesSummaryCopyWith < $Res > {
factory $SalesSummaryCopyWith (
SalesSummary value ,
$Res Function ( SalesSummary ) then ,
) = _ $SalesSummaryCopyWithImpl < $Res , SalesSummary > ;
@ useResult
$Res call ( {
int totalSales ,
int totalOrders ,
int totalItems ,
double averageOrderValue ,
int totalTax ,
int totalDiscount ,
int netSales ,
} ) ;
}
/// @nodoc
class _ $SalesSummaryCopyWithImpl < $Res , $Val extends SalesSummary >
implements $SalesSummaryCopyWith < $Res > {
_ $SalesSummaryCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of SalesSummary
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? totalSales = null ,
Object ? totalOrders = null ,
Object ? totalItems = null ,
Object ? averageOrderValue = null ,
Object ? totalTax = null ,
Object ? totalDiscount = null ,
Object ? netSales = null ,
} ) {
return _then (
_value . copyWith (
totalSales: null = = totalSales
? _value . totalSales
: totalSales // ignore: cast_nullable_to_non_nullable
as int ,
totalOrders: null = = totalOrders
? _value . totalOrders
: totalOrders // ignore: cast_nullable_to_non_nullable
as int ,
totalItems: null = = totalItems
? _value . totalItems
: totalItems // ignore: cast_nullable_to_non_nullable
as int ,
averageOrderValue: null = = averageOrderValue
? _value . averageOrderValue
: averageOrderValue // ignore: cast_nullable_to_non_nullable
as double ,
totalTax: null = = totalTax
? _value . totalTax
: totalTax // ignore: cast_nullable_to_non_nullable
as int ,
totalDiscount: null = = totalDiscount
? _value . totalDiscount
: totalDiscount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $SalesSummaryImplCopyWith < $Res >
implements $SalesSummaryCopyWith < $Res > {
factory _ $ $SalesSummaryImplCopyWith (
_ $SalesSummaryImpl value ,
$Res Function ( _ $SalesSummaryImpl ) then ,
) = __ $ $SalesSummaryImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
int totalSales ,
int totalOrders ,
int totalItems ,
double averageOrderValue ,
int totalTax ,
int totalDiscount ,
int netSales ,
} ) ;
}
/// @nodoc
class __ $ $SalesSummaryImplCopyWithImpl < $Res >
extends _ $SalesSummaryCopyWithImpl < $Res , _ $SalesSummaryImpl >
implements _ $ $SalesSummaryImplCopyWith < $Res > {
__ $ $SalesSummaryImplCopyWithImpl (
_ $SalesSummaryImpl _value ,
$Res Function ( _ $SalesSummaryImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of SalesSummary
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? totalSales = null ,
Object ? totalOrders = null ,
Object ? totalItems = null ,
Object ? averageOrderValue = null ,
Object ? totalTax = null ,
Object ? totalDiscount = null ,
Object ? netSales = null ,
} ) {
return _then (
_ $SalesSummaryImpl (
totalSales: null = = totalSales
? _value . totalSales
: totalSales // ignore: cast_nullable_to_non_nullable
as int ,
totalOrders: null = = totalOrders
? _value . totalOrders
: totalOrders // ignore: cast_nullable_to_non_nullable
as int ,
totalItems: null = = totalItems
? _value . totalItems
: totalItems // ignore: cast_nullable_to_non_nullable
as int ,
averageOrderValue: null = = averageOrderValue
? _value . averageOrderValue
: averageOrderValue // ignore: cast_nullable_to_non_nullable
as double ,
totalTax: null = = totalTax
? _value . totalTax
: totalTax // ignore: cast_nullable_to_non_nullable
as int ,
totalDiscount: null = = totalDiscount
? _value . totalDiscount
: totalDiscount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
) ,
) ;
}
}
/// @nodoc
class _ $SalesSummaryImpl implements _SalesSummary {
const _ $SalesSummaryImpl ( {
required this . totalSales ,
required this . totalOrders ,
required this . totalItems ,
required this . averageOrderValue ,
required this . totalTax ,
required this . totalDiscount ,
required this . netSales ,
} ) ;
@ override
final int totalSales ;
@ override
final int totalOrders ;
@ override
final int totalItems ;
@ override
final double averageOrderValue ;
@ override
final int totalTax ;
@ override
final int totalDiscount ;
@ override
final int netSales ;
@ override
String toString ( ) {
return ' SalesSummary(totalSales: $ totalSales , totalOrders: $ totalOrders , totalItems: $ totalItems , averageOrderValue: $ averageOrderValue , totalTax: $ totalTax , totalDiscount: $ totalDiscount , netSales: $ netSales ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $SalesSummaryImpl & &
( identical ( other . totalSales , totalSales ) | |
other . totalSales = = totalSales ) & &
( identical ( other . totalOrders , totalOrders ) | |
other . totalOrders = = totalOrders ) & &
( identical ( other . totalItems , totalItems ) | |
other . totalItems = = totalItems ) & &
( identical ( other . averageOrderValue , averageOrderValue ) | |
other . averageOrderValue = = averageOrderValue ) & &
( identical ( other . totalTax , totalTax ) | |
other . totalTax = = totalTax ) & &
( identical ( other . totalDiscount , totalDiscount ) | |
other . totalDiscount = = totalDiscount ) & &
( identical ( other . netSales , netSales ) | |
other . netSales = = netSales ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
totalSales ,
totalOrders ,
totalItems ,
averageOrderValue ,
totalTax ,
totalDiscount ,
netSales ,
) ;
/// Create a copy of SalesSummary
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $SalesSummaryImplCopyWith < _ $SalesSummaryImpl > get copyWith = >
__ $ $SalesSummaryImplCopyWithImpl < _ $SalesSummaryImpl > ( this , _ $identity ) ;
}
abstract class _SalesSummary implements SalesSummary {
const factory _SalesSummary ( {
required final int totalSales ,
required final int totalOrders ,
required final int totalItems ,
required final double averageOrderValue ,
required final int totalTax ,
required final int totalDiscount ,
required final int netSales ,
} ) = _ $SalesSummaryImpl ;
@ override
int get totalSales ;
@ override
int get totalOrders ;
@ override
int get totalItems ;
@ override
double get averageOrderValue ;
@ override
int get totalTax ;
@ override
int get totalDiscount ;
@ override
int get netSales ;
/// Create a copy of SalesSummary
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $SalesSummaryImplCopyWith < _ $SalesSummaryImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
mixin _ $SalesAnalyticItem {
DateTime get date = > throw _privateConstructorUsedError ;
int get sales = > throw _privateConstructorUsedError ;
int get orders = > throw _privateConstructorUsedError ;
int get items = > throw _privateConstructorUsedError ;
int get tax = > throw _privateConstructorUsedError ;
int get discount = > throw _privateConstructorUsedError ;
int get netSales = > throw _privateConstructorUsedError ;
/// Create a copy of SalesAnalyticItem
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
$SalesAnalyticItemCopyWith < SalesAnalyticItem > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $SalesAnalyticItemCopyWith < $Res > {
factory $SalesAnalyticItemCopyWith (
SalesAnalyticItem value ,
$Res Function ( SalesAnalyticItem ) then ,
) = _ $SalesAnalyticItemCopyWithImpl < $Res , SalesAnalyticItem > ;
@ useResult
$Res call ( {
DateTime date ,
int sales ,
int orders ,
int items ,
int tax ,
int discount ,
int netSales ,
} ) ;
}
/// @nodoc
class _ $SalesAnalyticItemCopyWithImpl < $Res , $Val extends SalesAnalyticItem >
implements $SalesAnalyticItemCopyWith < $Res > {
_ $SalesAnalyticItemCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of SalesAnalyticItem
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? date = null ,
Object ? sales = null ,
Object ? orders = null ,
Object ? items = null ,
Object ? tax = null ,
Object ? discount = null ,
Object ? netSales = null ,
} ) {
return _then (
_value . copyWith (
date: null = = date
? _value . date
: date // ignore: cast_nullable_to_non_nullable
as DateTime ,
sales: null = = sales
? _value . sales
: sales // ignore: cast_nullable_to_non_nullable
as int ,
orders: null = = orders
? _value . orders
: orders // ignore: cast_nullable_to_non_nullable
as int ,
items: null = = items
? _value . items
: items // ignore: cast_nullable_to_non_nullable
as int ,
tax: null = = tax
? _value . tax
: tax // ignore: cast_nullable_to_non_nullable
as int ,
discount: null = = discount
? _value . discount
: discount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
)
as $Val ,
) ;
}
}
/// @nodoc
abstract class _ $ $SalesAnalyticItemImplCopyWith < $Res >
implements $SalesAnalyticItemCopyWith < $Res > {
factory _ $ $SalesAnalyticItemImplCopyWith (
_ $SalesAnalyticItemImpl value ,
$Res Function ( _ $SalesAnalyticItemImpl ) then ,
) = __ $ $SalesAnalyticItemImplCopyWithImpl < $Res > ;
@ override
@ useResult
$Res call ( {
DateTime date ,
int sales ,
int orders ,
int items ,
int tax ,
int discount ,
int netSales ,
} ) ;
}
/// @nodoc
class __ $ $SalesAnalyticItemImplCopyWithImpl < $Res >
extends _ $SalesAnalyticItemCopyWithImpl < $Res , _ $SalesAnalyticItemImpl >
implements _ $ $SalesAnalyticItemImplCopyWith < $Res > {
__ $ $SalesAnalyticItemImplCopyWithImpl (
_ $SalesAnalyticItemImpl _value ,
$Res Function ( _ $SalesAnalyticItemImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of SalesAnalyticItem
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( {
Object ? date = null ,
Object ? sales = null ,
Object ? orders = null ,
Object ? items = null ,
Object ? tax = null ,
Object ? discount = null ,
Object ? netSales = null ,
} ) {
return _then (
_ $SalesAnalyticItemImpl (
date: null = = date
? _value . date
: date // ignore: cast_nullable_to_non_nullable
as DateTime ,
sales: null = = sales
? _value . sales
: sales // ignore: cast_nullable_to_non_nullable
as int ,
orders: null = = orders
? _value . orders
: orders // ignore: cast_nullable_to_non_nullable
as int ,
items: null = = items
? _value . items
: items // ignore: cast_nullable_to_non_nullable
as int ,
tax: null = = tax
? _value . tax
: tax // ignore: cast_nullable_to_non_nullable
as int ,
discount: null = = discount
? _value . discount
: discount // ignore: cast_nullable_to_non_nullable
as int ,
netSales: null = = netSales
? _value . netSales
: netSales // ignore: cast_nullable_to_non_nullable
as int ,
) ,
) ;
}
}
/// @nodoc
class _ $SalesAnalyticItemImpl implements _SalesAnalyticItem {
const _ $SalesAnalyticItemImpl ( {
required this . date ,
required this . sales ,
required this . orders ,
required this . items ,
required this . tax ,
required this . discount ,
required this . netSales ,
} ) ;
@ override
final DateTime date ;
@ override
final int sales ;
@ override
final int orders ;
@ override
final int items ;
@ override
final int tax ;
@ override
final int discount ;
@ override
final int netSales ;
@ override
String toString ( ) {
return ' SalesAnalyticItem(date: $ date , sales: $ sales , orders: $ orders , items: $ items , tax: $ tax , discount: $ discount , netSales: $ netSales ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $SalesAnalyticItemImpl & &
( identical ( other . date , date ) | | other . date = = date ) & &
( identical ( other . sales , sales ) | | other . sales = = sales ) & &
( identical ( other . orders , orders ) | | other . orders = = orders ) & &
( identical ( other . items , items ) | | other . items = = items ) & &
( identical ( other . tax , tax ) | | other . tax = = tax ) & &
( identical ( other . discount , discount ) | |
other . discount = = discount ) & &
( identical ( other . netSales , netSales ) | |
other . netSales = = netSales ) ) ;
}
@ override
int get hashCode = > Object . hash (
runtimeType ,
date ,
sales ,
orders ,
items ,
tax ,
discount ,
netSales ,
) ;
/// Create a copy of SalesAnalyticItem
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $SalesAnalyticItemImplCopyWith < _ $SalesAnalyticItemImpl > get copyWith = >
__ $ $SalesAnalyticItemImplCopyWithImpl < _ $SalesAnalyticItemImpl > (
this ,
_ $identity ,
) ;
}
abstract class _SalesAnalyticItem implements SalesAnalyticItem {
const factory _SalesAnalyticItem ( {
required final DateTime date ,
required final int sales ,
required final int orders ,
required final int items ,
required final int tax ,
required final int discount ,
required final int netSales ,
} ) = _ $SalesAnalyticItemImpl ;
@ override
DateTime get date ;
@ override
int get sales ;
@ override
int get orders ;
@ override
int get items ;
@ override
int get tax ;
@ override
int get discount ;
@ override
int get netSales ;
/// Create a copy of SalesAnalyticItem
/// with the given fields replaced by the non-null parameter values.
@ override
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $SalesAnalyticItemImplCopyWith < _ $SalesAnalyticItemImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
2025-11-03 16:24:11 +07:00
/// @nodoc
mixin _ $AnalyticFailure {
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ApiFailure failure ) serverError ,
required TResult Function ( ) unexpectedError ,
required TResult Function ( String erroMessage ) dynamicErrorMessage ,
} ) = > throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult ? whenOrNull < TResult extends Object ? > ( {
TResult ? Function ( ApiFailure failure ) ? serverError ,
TResult ? Function ( ) ? unexpectedError ,
TResult ? Function ( String erroMessage ) ? dynamicErrorMessage ,
} ) = > throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ApiFailure failure ) ? serverError ,
TResult Function ( ) ? unexpectedError ,
TResult Function ( String erroMessage ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) = > throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( _ServerError value ) serverError ,
required TResult Function ( _UnexpectedError value ) unexpectedError ,
required TResult Function ( _DynamicErrorMessage value ) dynamicErrorMessage ,
} ) = > throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult ? mapOrNull < TResult extends Object ? > ( {
TResult ? Function ( _ServerError value ) ? serverError ,
TResult ? Function ( _UnexpectedError value ) ? unexpectedError ,
TResult ? Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
} ) = > throw _privateConstructorUsedError ;
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( _ServerError value ) ? serverError ,
TResult Function ( _UnexpectedError value ) ? unexpectedError ,
TResult Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) = > throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class $AnalyticFailureCopyWith < $Res > {
factory $AnalyticFailureCopyWith (
AnalyticFailure value ,
$Res Function ( AnalyticFailure ) then ,
) = _ $AnalyticFailureCopyWithImpl < $Res , AnalyticFailure > ;
}
/// @nodoc
class _ $AnalyticFailureCopyWithImpl < $Res , $Val extends AnalyticFailure >
implements $AnalyticFailureCopyWith < $Res > {
_ $AnalyticFailureCopyWithImpl ( this . _value , this . _then ) ;
// ignore: unused_field
final $Val _value ;
// ignore: unused_field
final $Res Function ( $Val ) _then ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
}
/// @nodoc
abstract class _ $ $ServerErrorImplCopyWith < $Res > {
factory _ $ $ServerErrorImplCopyWith (
_ $ServerErrorImpl value ,
$Res Function ( _ $ServerErrorImpl ) then ,
) = __ $ $ServerErrorImplCopyWithImpl < $Res > ;
@ useResult
$Res call ( { ApiFailure failure } ) ;
$ApiFailureCopyWith < $Res > get failure ;
}
/// @nodoc
class __ $ $ServerErrorImplCopyWithImpl < $Res >
extends _ $AnalyticFailureCopyWithImpl < $Res , _ $ServerErrorImpl >
implements _ $ $ServerErrorImplCopyWith < $Res > {
__ $ $ServerErrorImplCopyWithImpl (
_ $ServerErrorImpl _value ,
$Res Function ( _ $ServerErrorImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( { Object ? failure = null } ) {
return _then (
_ $ServerErrorImpl (
null = = failure
? _value . failure
: failure // ignore: cast_nullable_to_non_nullable
as ApiFailure ,
) ,
) ;
}
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ override
@ pragma ( ' vm:prefer-inline ' )
$ApiFailureCopyWith < $Res > get failure {
return $ApiFailureCopyWith < $Res > ( _value . failure , ( value ) {
return _then ( _value . copyWith ( failure: value ) ) ;
} ) ;
}
}
/// @nodoc
class _ $ServerErrorImpl implements _ServerError {
const _ $ServerErrorImpl ( this . failure ) ;
@ override
final ApiFailure failure ;
@ override
String toString ( ) {
return ' AnalyticFailure.serverError(failure: $ failure ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $ServerErrorImpl & &
( identical ( other . failure , failure ) | | other . failure = = failure ) ) ;
}
@ override
int get hashCode = > Object . hash ( runtimeType , failure ) ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $ServerErrorImplCopyWith < _ $ServerErrorImpl > get copyWith = >
__ $ $ServerErrorImplCopyWithImpl < _ $ServerErrorImpl > ( this , _ $identity ) ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ApiFailure failure ) serverError ,
required TResult Function ( ) unexpectedError ,
required TResult Function ( String erroMessage ) dynamicErrorMessage ,
} ) {
return serverError ( failure ) ;
}
@ override
@ optionalTypeArgs
TResult ? whenOrNull < TResult extends Object ? > ( {
TResult ? Function ( ApiFailure failure ) ? serverError ,
TResult ? Function ( ) ? unexpectedError ,
TResult ? Function ( String erroMessage ) ? dynamicErrorMessage ,
} ) {
return serverError ? . call ( failure ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ApiFailure failure ) ? serverError ,
TResult Function ( ) ? unexpectedError ,
TResult Function ( String erroMessage ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( serverError ! = null ) {
return serverError ( failure ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( _ServerError value ) serverError ,
required TResult Function ( _UnexpectedError value ) unexpectedError ,
required TResult Function ( _DynamicErrorMessage value ) dynamicErrorMessage ,
} ) {
return serverError ( this ) ;
}
@ override
@ optionalTypeArgs
TResult ? mapOrNull < TResult extends Object ? > ( {
TResult ? Function ( _ServerError value ) ? serverError ,
TResult ? Function ( _UnexpectedError value ) ? unexpectedError ,
TResult ? Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
} ) {
return serverError ? . call ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( _ServerError value ) ? serverError ,
TResult Function ( _UnexpectedError value ) ? unexpectedError ,
TResult Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( serverError ! = null ) {
return serverError ( this ) ;
}
return orElse ( ) ;
}
}
abstract class _ServerError implements AnalyticFailure {
const factory _ServerError ( final ApiFailure failure ) = _ $ServerErrorImpl ;
ApiFailure get failure ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $ServerErrorImplCopyWith < _ $ServerErrorImpl > get copyWith = >
throw _privateConstructorUsedError ;
}
/// @nodoc
abstract class _ $ $UnexpectedErrorImplCopyWith < $Res > {
factory _ $ $UnexpectedErrorImplCopyWith (
_ $UnexpectedErrorImpl value ,
$Res Function ( _ $UnexpectedErrorImpl ) then ,
) = __ $ $UnexpectedErrorImplCopyWithImpl < $Res > ;
}
/// @nodoc
class __ $ $UnexpectedErrorImplCopyWithImpl < $Res >
extends _ $AnalyticFailureCopyWithImpl < $Res , _ $UnexpectedErrorImpl >
implements _ $ $UnexpectedErrorImplCopyWith < $Res > {
__ $ $UnexpectedErrorImplCopyWithImpl (
_ $UnexpectedErrorImpl _value ,
$Res Function ( _ $UnexpectedErrorImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
}
/// @nodoc
class _ $UnexpectedErrorImpl implements _UnexpectedError {
const _ $UnexpectedErrorImpl ( ) ;
@ override
String toString ( ) {
return ' AnalyticFailure.unexpectedError() ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & & other is _ $UnexpectedErrorImpl ) ;
}
@ override
int get hashCode = > runtimeType . hashCode ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ApiFailure failure ) serverError ,
required TResult Function ( ) unexpectedError ,
required TResult Function ( String erroMessage ) dynamicErrorMessage ,
} ) {
return unexpectedError ( ) ;
}
@ override
@ optionalTypeArgs
TResult ? whenOrNull < TResult extends Object ? > ( {
TResult ? Function ( ApiFailure failure ) ? serverError ,
TResult ? Function ( ) ? unexpectedError ,
TResult ? Function ( String erroMessage ) ? dynamicErrorMessage ,
} ) {
return unexpectedError ? . call ( ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ApiFailure failure ) ? serverError ,
TResult Function ( ) ? unexpectedError ,
TResult Function ( String erroMessage ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( unexpectedError ! = null ) {
return unexpectedError ( ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( _ServerError value ) serverError ,
required TResult Function ( _UnexpectedError value ) unexpectedError ,
required TResult Function ( _DynamicErrorMessage value ) dynamicErrorMessage ,
} ) {
return unexpectedError ( this ) ;
}
@ override
@ optionalTypeArgs
TResult ? mapOrNull < TResult extends Object ? > ( {
TResult ? Function ( _ServerError value ) ? serverError ,
TResult ? Function ( _UnexpectedError value ) ? unexpectedError ,
TResult ? Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
} ) {
return unexpectedError ? . call ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( _ServerError value ) ? serverError ,
TResult Function ( _UnexpectedError value ) ? unexpectedError ,
TResult Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( unexpectedError ! = null ) {
return unexpectedError ( this ) ;
}
return orElse ( ) ;
}
}
abstract class _UnexpectedError implements AnalyticFailure {
const factory _UnexpectedError ( ) = _ $UnexpectedErrorImpl ;
}
/// @nodoc
abstract class _ $ $DynamicErrorMessageImplCopyWith < $Res > {
factory _ $ $DynamicErrorMessageImplCopyWith (
_ $DynamicErrorMessageImpl value ,
$Res Function ( _ $DynamicErrorMessageImpl ) then ,
) = __ $ $DynamicErrorMessageImplCopyWithImpl < $Res > ;
@ useResult
$Res call ( { String erroMessage } ) ;
}
/// @nodoc
class __ $ $DynamicErrorMessageImplCopyWithImpl < $Res >
extends _ $AnalyticFailureCopyWithImpl < $Res , _ $DynamicErrorMessageImpl >
implements _ $ $DynamicErrorMessageImplCopyWith < $Res > {
__ $ $DynamicErrorMessageImplCopyWithImpl (
_ $DynamicErrorMessageImpl _value ,
$Res Function ( _ $DynamicErrorMessageImpl ) _then ,
) : super ( _value , _then ) ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ pragma ( ' vm:prefer-inline ' )
@ override
$Res call ( { Object ? erroMessage = null } ) {
return _then (
_ $DynamicErrorMessageImpl (
null = = erroMessage
? _value . erroMessage
: erroMessage // ignore: cast_nullable_to_non_nullable
as String ,
) ,
) ;
}
}
/// @nodoc
class _ $DynamicErrorMessageImpl implements _DynamicErrorMessage {
const _ $DynamicErrorMessageImpl ( this . erroMessage ) ;
@ override
final String erroMessage ;
@ override
String toString ( ) {
return ' AnalyticFailure.dynamicErrorMessage(erroMessage: $ erroMessage ) ' ;
}
@ override
bool operator = = ( Object other ) {
return identical ( this , other ) | |
( other . runtimeType = = runtimeType & &
other is _ $DynamicErrorMessageImpl & &
( identical ( other . erroMessage , erroMessage ) | |
other . erroMessage = = erroMessage ) ) ;
}
@ override
int get hashCode = > Object . hash ( runtimeType , erroMessage ) ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
@ override
@ pragma ( ' vm:prefer-inline ' )
_ $ $DynamicErrorMessageImplCopyWith < _ $DynamicErrorMessageImpl > get copyWith = >
__ $ $DynamicErrorMessageImplCopyWithImpl < _ $DynamicErrorMessageImpl > (
this ,
_ $identity ,
) ;
@ override
@ optionalTypeArgs
TResult when < TResult extends Object ? > ( {
required TResult Function ( ApiFailure failure ) serverError ,
required TResult Function ( ) unexpectedError ,
required TResult Function ( String erroMessage ) dynamicErrorMessage ,
} ) {
return dynamicErrorMessage ( erroMessage ) ;
}
@ override
@ optionalTypeArgs
TResult ? whenOrNull < TResult extends Object ? > ( {
TResult ? Function ( ApiFailure failure ) ? serverError ,
TResult ? Function ( ) ? unexpectedError ,
TResult ? Function ( String erroMessage ) ? dynamicErrorMessage ,
} ) {
return dynamicErrorMessage ? . call ( erroMessage ) ;
}
@ override
@ optionalTypeArgs
TResult maybeWhen < TResult extends Object ? > ( {
TResult Function ( ApiFailure failure ) ? serverError ,
TResult Function ( ) ? unexpectedError ,
TResult Function ( String erroMessage ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( dynamicErrorMessage ! = null ) {
return dynamicErrorMessage ( erroMessage ) ;
}
return orElse ( ) ;
}
@ override
@ optionalTypeArgs
TResult map < TResult extends Object ? > ( {
required TResult Function ( _ServerError value ) serverError ,
required TResult Function ( _UnexpectedError value ) unexpectedError ,
required TResult Function ( _DynamicErrorMessage value ) dynamicErrorMessage ,
} ) {
return dynamicErrorMessage ( this ) ;
}
@ override
@ optionalTypeArgs
TResult ? mapOrNull < TResult extends Object ? > ( {
TResult ? Function ( _ServerError value ) ? serverError ,
TResult ? Function ( _UnexpectedError value ) ? unexpectedError ,
TResult ? Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
} ) {
return dynamicErrorMessage ? . call ( this ) ;
}
@ override
@ optionalTypeArgs
TResult maybeMap < TResult extends Object ? > ( {
TResult Function ( _ServerError value ) ? serverError ,
TResult Function ( _UnexpectedError value ) ? unexpectedError ,
TResult Function ( _DynamicErrorMessage value ) ? dynamicErrorMessage ,
required TResult orElse ( ) ,
} ) {
if ( dynamicErrorMessage ! = null ) {
return dynamicErrorMessage ( this ) ;
}
return orElse ( ) ;
}
}
abstract class _DynamicErrorMessage implements AnalyticFailure {
const factory _DynamicErrorMessage ( final String erroMessage ) =
_ $DynamicErrorMessageImpl ;
String get erroMessage ;
/// Create a copy of AnalyticFailure
/// with the given fields replaced by the non-null parameter values.
@ JsonKey ( includeFromJson: false , includeToJson: false )
_ $ $DynamicErrorMessageImplCopyWith < _ $DynamicErrorMessageImpl > get copyWith = >
throw _privateConstructorUsedError ;
}