copyWith method

AdaptiveFile copyWith({
  1. String? path,
  2. String? name,
  3. Uint8List? bytes,
  4. String? mimeType,
  5. int? width,
  6. int? height,
  7. int? size,
  8. DateTime? lastModified,
})

Returns a copy of this file with modified attributes.

Implementation

AdaptiveFile copyWith({
  String? path,
  String? name,
  Uint8List? bytes,
  String? mimeType,
  int? width,
  int? height,
  int? size,
  DateTime? lastModified,
}) {
  return AdaptiveFile(
    path: path ?? this.path,
    name: name ?? this.name,
    bytes: bytes ?? this.bytes,
    mimeType: mimeType ?? this.mimeType,
    width: width ?? this.width,
    height: height ?? this.height,
    size: size ?? this.size,
    lastModified: lastModified ?? this.lastModified,
  );
}