copyWith method

MusicSelection copyWith({
  1. Duration? start,
  2. Duration? duration,
  3. String? localPath,
  4. double? volume,
})

Returns a copy with the given values replaced.

Implementation

MusicSelection copyWith({
  Duration? start,
  Duration? duration,
  String? localPath,
  double? volume,
}) => MusicSelection(
  track: track,
  start: start ?? this.start,
  duration: duration ?? this.duration,
  localPath: localPath ?? this.localPath,
  volume: volume ?? this.volume,
);