copyWith method

AnchoredMomentum copyWith({
  1. double? velocity,
  2. ScreenPoint? anchor,
  3. MomentumDecay? decay,
  4. MomentumSnap? snap,
})

A copy of this value with the given members replaced.

Implementation

AnchoredMomentum copyWith({
  double? velocity,
  ScreenPoint? anchor,
  MomentumDecay? decay,
  MomentumSnap? snap,
}) => AnchoredMomentum(
  velocity: velocity ?? this.velocity,
  anchor: anchor ?? this.anchor,
  decay: decay ?? this.decay,
  snap: snap ?? this.snap,
);