copyWith method

SentryEvent copyWith({
  1. SentryId? eventId,
  2. DateTime? timestamp,
  3. String? platform,
  4. String? logger,
  5. String? serverName,
  6. String? release,
  7. String? dist,
  8. String? environment,
  9. Map<String, String>? modules,
  10. SentryMessage? message,
  11. String? transaction,
  12. dynamic throwable,
  13. SentryException? exception,
  14. dynamic stackTrace,
  15. SentryLevel? level,
  16. String? culprit,
  17. Map<String, String>? tags,
  18. Map<String, dynamic>? extra,
  19. List<String>? fingerprint,
  20. SentryUser? user,
  21. Contexts? contexts,
  22. List<Breadcrumb>? breadcrumbs,
  23. SdkVersion? sdk,
  24. SentryRequest? request,
  25. DebugMeta? debugMeta,
})

Implementation

SentryEvent copyWith({
  SentryId? eventId,
  DateTime? timestamp,
  String? platform,
  String? logger,
  String? serverName,
  String? release,
  String? dist,
  String? environment,
  Map<String, String>? modules,
  SentryMessage? message,
  String? transaction,
  dynamic throwable,
  SentryException? exception,
  dynamic stackTrace,
  SentryLevel? level,
  String? culprit,
  Map<String, String>? tags,
  Map<String, dynamic>? extra,
  List<String>? fingerprint,
  SentryUser? user,
  Contexts? contexts,
  List<Breadcrumb>? breadcrumbs,
  SdkVersion? sdk,
  SentryRequest? request,
  DebugMeta? debugMeta,
}) =>
    SentryEvent(
      eventId: eventId ?? this.eventId,
      timestamp: timestamp ?? this.timestamp,
      platform: platform ?? this.platform,
      logger: logger ?? this.logger,
      serverName: serverName ?? this.serverName,
      release: release ?? this.release,
      dist: dist ?? this.dist,
      environment: environment ?? this.environment,
      modules: (modules != null ? Map.from(modules) : null) ?? this.modules,
      message: message ?? this.message,
      transaction: transaction ?? this.transaction,
      throwable: throwable ?? _throwable,
      exception: exception ?? this.exception,
      stackTrace: stackTrace ?? this.stackTrace,
      level: level ?? this.level,
      culprit: culprit ?? this.culprit,
      tags: (tags != null ? Map.from(tags) : null) ?? this.tags,
      extra: (extra != null ? Map.from(extra) : null) ?? this.extra,
      fingerprint: (fingerprint != null ? List.from(fingerprint) : null) ??
          this.fingerprint,
      user: user ?? this.user,
      contexts: contexts ?? this.contexts,
      breadcrumbs: (breadcrumbs != null ? List.from(breadcrumbs) : null) ??
          this.breadcrumbs,
      sdk: sdk ?? this.sdk,
      request: request ?? this.request,
      debugMeta: debugMeta ?? this.debugMeta,
    );