copyWith method

FilePart copyWith({
  1. String? mediaType,
  2. Uri? url,
  3. Uint8List? bytes,
  4. String? name,
})

Returns a copy with the given fields replaced.

Implementation

FilePart copyWith({
  String? mediaType,
  Uri? url,
  Uint8List? bytes,
  String? name,
}) =>
    FilePart(
      mediaType: mediaType ?? this.mediaType,
      url: url ?? this.url,
      bytes: bytes ?? this.bytes,
      name: name ?? this.name,
    );