copyWith method

PollOption<T> copyWith({
  1. String? label,
  2. int? voteCount,
})

Implementation

PollOption<T> copyWith({String? label, int? voteCount}) {
  return PollOption<T>(
    id: id,
    label: label ?? this.label,
    voteCount: voteCount ?? this.voteCount,
  );
}