copyWith method

Location copyWith({
  1. String? uuid,
  2. DateTime? timestamp,
  3. int? age,
  4. String? event,
  5. bool? isMoving,
  6. bool? isHeartbeat,
  7. bool? isMock,
  8. Coords? coords,
  9. Activity? activity,
  10. Battery? battery,
  11. Geofence? geofence,
  12. double? odometer,
  13. JsonMap? extras,
})

Implementation

Location copyWith({
  String? uuid,
  DateTime? timestamp,
  int? age,
  String? event,
  bool? isMoving,
  bool? isHeartbeat,
  bool? isMock,
  Coords? coords,
  Activity? activity,
  Battery? battery,
  Geofence? geofence,
  double? odometer,
  JsonMap? extras,
}) {
  return Location(
    uuid: uuid ?? this.uuid,
    timestamp: timestamp ?? this.timestamp,
    age: age ?? this.age,
    event: event ?? this.event,
    isMoving: isMoving ?? this.isMoving,
    isHeartbeat: isHeartbeat ?? this.isHeartbeat,
    isMock: isMock ?? this.isMock,
    coords: coords ?? this.coords,
    activity: activity ?? this.activity,
    battery: battery ?? this.battery,
    geofence: geofence ?? this.geofence,
    odometer: odometer ?? this.odometer,
    extras: extras ?? this.extras,
  );
}