copyWith method

LowBatteryConfig copyWith({
  1. double? threshold,
  2. Duration? throttleInterval,
  3. bool? disableAutoSync,
})

Creates a copy with the given fields replaced.

Implementation

LowBatteryConfig copyWith({
  double? threshold,
  Duration? throttleInterval,
  bool? disableAutoSync,
}) {
  return LowBatteryConfig(
    threshold: threshold ?? this.threshold,
    throttleInterval: throttleInterval ?? this.throttleInterval,
    disableAutoSync: disableAutoSync ?? this.disableAutoSync,
  );
}