copyWith method

WordState copyWith({
  1. int? index,
  2. bool? isFinal,
  3. List<String>? words,
  4. int? failure,
})

Implementation

WordState copyWith(
        {int? index, bool? isFinal, List<String>? words, int? failure}) =>
    WordState(
      failure: failure ?? this.failure,
      index: index ?? this.index,
      words: words ?? this.words,
      isFinal: isFinal ?? this.isFinal,
    );