reportProgress method
Reports task progress (0.0–1.0) to be streamed to listeners.
Call this from within your task handler to update the progress UI. Progress values outside 0.0–1.0 will be clamped.
Implementation
Future<void> reportProgress(double progress) async {
final clamped = progress.clamp(0.0, 1.0);
await _reportProgressFn?.call(clamped);
}