copyWith method
UserAcademicSummary
copyWith({ - int? id,
- int? user,
- int? semester,
- int? year,
- int? term,
- Value<double?> average = const Value.absent(),
- Value<double?> conduct = const Value.absent(),
- Value<double?> totalCredits = const Value.absent(),
- Value<double?> creditsPassed = const Value.absent(),
- Value<String?> note = const Value.absent(),
- Value<double?> gpa = const Value.absent(),
})
Implementation
UserAcademicSummary copyWith({
int? id,
int? user,
int? semester,
int? year,
int? term,
Value<double?> average = const Value.absent(),
Value<double?> conduct = const Value.absent(),
Value<double?> totalCredits = const Value.absent(),
Value<double?> creditsPassed = const Value.absent(),
Value<String?> note = const Value.absent(),
Value<double?> gpa = const Value.absent(),
}) => UserAcademicSummary(
id: id ?? this.id,
user: user ?? this.user,
semester: semester ?? this.semester,
year: year ?? this.year,
term: term ?? this.term,
average: average.present ? average.value : this.average,
conduct: conduct.present ? conduct.value : this.conduct,
totalCredits: totalCredits.present ? totalCredits.value : this.totalCredits,
creditsPassed: creditsPassed.present
? creditsPassed.value
: this.creditsPassed,
note: note.present ? note.value : this.note,
gpa: gpa.present ? gpa.value : this.gpa,
);