copyWith method

Slot copyWith({
  1. String? id,
  2. Meta? meta,
  3. FixedList<Identifier>? identifier,
  4. List<CodeableConcept>? serviceCategory,
  5. List<CodeableConcept>? serviceType,
  6. List<CodeableConcept>? specialty,
  7. CodeableConcept? appointmentType,
  8. String? schedule,
  9. SlotStatus? status,
  10. DateTime? start,
  11. DateTime? end,
  12. bool? overbooked,
  13. String? comment,
})

Creates a copy of the Slot instance and allows for non-destructive mutation.

Implementation

Slot copyWith({
  String? id,
  Meta? meta,
  FixedList<Identifier>? identifier,
  List<CodeableConcept>? serviceCategory,
  List<CodeableConcept>? serviceType,
  List<CodeableConcept>? specialty,
  CodeableConcept? appointmentType,
  String? schedule,
  SlotStatus? status,
  DateTime? start,
  DateTime? end,
  bool? overbooked,
  String? comment,
}) =>
    Slot(
      id: id ?? this.id,
      meta: meta ?? this.meta,
      identifier: identifier ?? this.identifier,
      serviceCategory: serviceCategory ?? this.serviceCategory,
      serviceType: serviceType ?? this.serviceType,
      specialty: specialty ?? this.specialty,
      appointmentType: appointmentType ?? this.appointmentType,
      schedule: schedule ?? this.schedule,
      status: status ?? this.status,
      start: start ?? this.start,
      end: end ?? this.end,
      overbooked: overbooked ?? this.overbooked,
      comment: comment ?? this.comment,
    );