copyWith method

NoteAnnotation copyWith({
  1. String? id,
  2. int? pageNumber,
  3. DateTime? createdAt,
  4. DateTime? modifiedAt,
  5. Offset? position,
  6. String? text,
  7. Color? backgroundColor,
  8. Color? textColor,
  9. double? fontSize,
})

Implementation

NoteAnnotation copyWith({
  String? id,
  int? pageNumber,
  DateTime? createdAt,
  DateTime? modifiedAt,
  Offset? position,
  String? text,
  Color? backgroundColor,
  Color? textColor,
  double? fontSize,
}) {
  return NoteAnnotation(
    id: id ?? this.id,
    pageNumber: pageNumber ?? this.pageNumber,
    createdAt: createdAt ?? this.createdAt,
    modifiedAt: modifiedAt ?? this.modifiedAt,
    position: position ?? this.position,
    text: text ?? this.text,
    backgroundColor: backgroundColor ?? this.backgroundColor,
    textColor: textColor ?? this.textColor,
    fontSize: fontSize ?? this.fontSize,
  );
}