copyWith method

ChatBoost copyWith({
  1. String? id,
  2. int? count,
  3. ChatBoostSource? source,
  4. int? startDate,
  5. int? expirationDate,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

ChatBoost copyWith({
  String? id,
  int? count,
  ChatBoostSource? source,
  int? startDate,
  int? expirationDate,
}) =>
    ChatBoost(
      id: id ?? this.id,
      count: count ?? this.count,
      source: source ?? this.source,
      startDate: startDate ?? this.startDate,
      expirationDate: expirationDate ?? this.expirationDate,
    );