PreloadProgress class

预加载进度信息

Constructors

PreloadProgress({required PreloadManagerState state, required int totalTasks, required int completedTasks, required int runningTasks, required int failedTasks, required double progress, DateTime? startTime, Duration? estimatedTimeRemaining, Map<String, Object> failedTasksDetails = const {}})
const

Properties

completedTasks int
已完成任务数
final
estimatedTimeRemaining Duration?
预计剩余时间(基于当前进度计算)
final
failedTasks int
失败的任务数
final
failedTasksDetails Map<String, Object>
失败的任务详情
final
hashCode int
The hash code for this object.
no setterinherited
isCompleted bool
是否已完成
no setter
isFailed bool
是否失败
no setter
isRunning bool
是否正在进行
no setter
progress double
完成百分比 (0.0 - 1.0)
final
progressPercentage String
完成百分比(格式化的字符串)
no setter
runningTasks int
正在进行的任务数
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
startTime DateTime?
开始时间
final
state PreloadManagerState
当前状态
final
totalTasks int
总任务数
final

Methods

copyWith({PreloadManagerState? state, int? totalTasks, int? completedTasks, int? runningTasks, int? failedTasks, double? progress, Map<String, Object>? failedTasksDetails, DateTime? startTime, Duration? estimatedTimeRemaining}) PreloadProgress
创建副本并修改部分属性
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

initial(int totalTasks) PreloadProgress
创建初始进度