copyWith method

Event copyWith({
  1. String? id,
  2. String? name,
  3. String? description,
  4. String? deviceModelId,
  5. String? icon,
  6. List<MatchGroup>? conditions,
  7. List<String>? triggeredAlarms,
  8. EmailTemplate? emailTemplate,
  9. SMSTemplate? smsTemplate,
  10. FCMTemplate? fcmTemplate,
  11. VoiceTemplate? voiceTemplate,
  12. String? $id,
  13. int? cstamp,
  14. String? cby,
  15. String? uby,
  16. int? ustamp,
})

Implementation

Event copyWith(
    {String? id,
    String? name,
    String? description,
    String? deviceModelId,
    String? icon,
    List<MatchGroup>? conditions,
    List<String>? triggeredAlarms,
    EmailTemplate? emailTemplate,
    SMSTemplate? smsTemplate,
    FCMTemplate? fcmTemplate,
    VoiceTemplate? voiceTemplate,
    String? $id,
    int? cstamp,
    String? cby,
    String? uby,
    int? ustamp}) {
  return Event(
      id: id ?? this.id,
      name: name ?? this.name,
      description: description ?? this.description,
      deviceModelId: deviceModelId ?? this.deviceModelId,
      icon: icon ?? this.icon,
      conditions: conditions ?? this.conditions,
      triggeredAlarms: triggeredAlarms ?? this.triggeredAlarms,
      emailTemplate: emailTemplate ?? this.emailTemplate,
      smsTemplate: smsTemplate ?? this.smsTemplate,
      fcmTemplate: fcmTemplate ?? this.fcmTemplate,
      voiceTemplate: voiceTemplate ?? this.voiceTemplate,
      $id: $id ?? this.$id,
      cstamp: cstamp ?? this.cstamp,
      cby: cby ?? this.cby,
      uby: uby ?? this.uby,
      ustamp: ustamp ?? this.ustamp);
}