copyWith method

HizbResult copyWith({
  1. int? hizb,
  2. int? juz,
  3. int? totalAyat,
  4. List<AyahWithSurah>? ayat,
  5. String? source,
})

Creates a copy of this HizbResult with the given fields replaced with new values

Implementation

HizbResult copyWith({
  int? hizb,
  int? juz,
  int? totalAyat,
  List<AyahWithSurah>? ayat,
  String? source,
}) {
  return HizbResult(
    hizb: hizb ?? this.hizb,
    juz: juz ?? this.juz,
    totalAyat: totalAyat ?? this.totalAyat,
    ayat: ayat ?? this.ayat,
    source: source ?? this.source,
  );
}