copyWith method

CourseSummaryByIdResponse copyWith({
  1. int? id,
  2. String? name,
  3. PublicationState? state,
  4. String? publishDate,
  5. String? publishedAt,
  6. CourseSettings? settings,
  7. int? subjectId,
  8. bool? isArchived,
  9. CourseCategory? category,
  10. CourseCategoryCover? categoryCover,
})

Implementation

CourseSummaryByIdResponse copyWith({
  int? id,
  String? name,
  enums.PublicationState? state,
  String? publishDate,
  String? publishedAt,
  CourseSettings? settings,
  int? subjectId,
  bool? isArchived,
  enums.CourseCategory? category,
  enums.CourseCategoryCover? categoryCover,
}) {
  return CourseSummaryByIdResponse(
    id: id ?? this.id,
    name: name ?? this.name,
    state: state ?? this.state,
    publishDate: publishDate ?? this.publishDate,
    publishedAt: publishedAt ?? this.publishedAt,
    settings: settings ?? this.settings,
    subjectId: subjectId ?? this.subjectId,
    isArchived: isArchived ?? this.isArchived,
    category: category ?? this.category,
    categoryCover: categoryCover ?? this.categoryCover,
  );
}