copyWith method

DatumMetrics copyWith({
  1. int? totalSyncOperations,
  2. int? successfulSyncs,
  3. int? failedSyncs,
  4. int? conflictsDetected,
  5. int? conflictsResolvedAutomatically,
  6. int? userSwitchCount,
  7. Set<String>? activeUsers,
  8. int? totalBytesPushed,
  9. int? totalBytesPulled,
})

Creates a copy of this metrics object with updated values.

Implementation

DatumMetrics copyWith({
  int? totalSyncOperations,
  int? successfulSyncs,
  int? failedSyncs,
  int? conflictsDetected,
  int? conflictsResolvedAutomatically,
  int? userSwitchCount,
  Set<String>? activeUsers,
  int? totalBytesPushed,
  int? totalBytesPulled,
}) {
  return DatumMetrics(
    totalSyncOperations: totalSyncOperations ?? this.totalSyncOperations,
    successfulSyncs: successfulSyncs ?? this.successfulSyncs,
    failedSyncs: failedSyncs ?? this.failedSyncs,
    conflictsDetected: conflictsDetected ?? this.conflictsDetected,
    conflictsResolvedAutomatically: conflictsResolvedAutomatically ?? this.conflictsResolvedAutomatically,
    userSwitchCount: userSwitchCount ?? this.userSwitchCount,
    activeUsers: activeUsers ?? this.activeUsers,
    totalBytesPushed: totalBytesPushed ?? this.totalBytesPushed,
    totalBytesPulled: totalBytesPulled ?? this.totalBytesPulled,
  );
}