WarmupProgress class
A single progress snapshot emitted during backend warmup.
Stream contract
- Events are emitted as work progresses.
- The stream completes (via
onDone) when all warmup tasks finish. - Failures are surfaced as events with isDone =
trueand a non-null error — the stream never errors, so callers don't needonError.
Typical usage (Flutter)
MiniAVTools.warmup().listen(
(p) {
if (p.fraction != null) {
setState(() => _download = p.fraction!);
}
},
onDone: () => setState(() => _ready = true),
);
Constructors
Properties
- backendName → String
-
Name of the backend emitting this event (e.g.
"ffmpeg").final - bytesReceived → int?
-
Bytes received so far (only present for download-type tasks).
final
- error → Object?
-
Set when task completed with an error. isDone is always
truewhen this is non-null.final - fraction → double?
-
Download progress in
[0.0, 1.0], ornullwhen:no setter - hashCode → int
-
The hash code for this object.
no setterinherited
- isDone → bool
-
Whether this event marks the end of task.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- task → String
-
Human-readable description of the current task
(e.g.
"Downloading FFmpeg").final - totalBytes → int?
-
Total expected bytes.
nullmeans the total is unknown (e.g. the server did not sendContent-Length).final
Methods
-
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