copyWith method

H5PRequestModel copyWith({
  1. String? refName,
  2. String? url,
  3. String? error,
  4. H5PFileStatus? status,
  5. int? priority,
  6. String? localPath,
})

Copy model with updated fields

Implementation

H5PRequestModel copyWith({
  String? refName,
  String? url,
  String? error,
  H5PFileStatus? status,
  int? priority,
  String? localPath,
}) {
  return H5PRequestModel(
    refName: refName ?? this.refName,
    url: url ?? this.url,
    error: error ?? this.error,
    status: status ?? this.status,
    priority: priority ?? this.priority,
    localPath: localPath ?? this.localPath,
  );
}