40 lines
1.1 KiB
Dart
40 lines
1.1 KiB
Dart
|
part of 'user_path_bloc.dart';
|
||
|
|
||
|
@immutable
|
||
|
abstract class UserPathState {}
|
||
|
|
||
|
// class UserPathInitial extends UserPathState {
|
||
|
// UserPathInitial({required super.InitialPoints, required super.LivePoints, required super.from, required super.to});
|
||
|
// }
|
||
|
|
||
|
final class MainUserPathState extends UserPathState {
|
||
|
final IList<Point> initialPoints;
|
||
|
final IList<Point> livePoints;
|
||
|
|
||
|
final DateTime from;
|
||
|
final DateTime to;
|
||
|
|
||
|
final bool subscribed;
|
||
|
|
||
|
MainUserPathState({
|
||
|
required this.initialPoints,
|
||
|
required this.livePoints,
|
||
|
required this.from,
|
||
|
required this.to,
|
||
|
this.subscribed = false,
|
||
|
});
|
||
|
|
||
|
MainUserPathState.copy(MainUserPathState original,
|
||
|
{IList<Point>? initialPoints,
|
||
|
IList<Point>? livePoints,
|
||
|
DateTime? from,
|
||
|
DateTime? to,
|
||
|
bool? subscribed})
|
||
|
: this(
|
||
|
initialPoints: initialPoints ?? original.initialPoints,
|
||
|
livePoints: livePoints ?? original.livePoints,
|
||
|
from: from ?? original.from,
|
||
|
to: to ?? original.to,
|
||
|
subscribed: subscribed ?? original.subscribed);
|
||
|
}
|