ImageFileAttachment constructor

ImageFileAttachment({
  1. required String name,
  2. required String mimeType,
  3. required Uint8List bytes,
})

Creates an ImageFileAttachment with the given name, MIME type, and bytes.

name is the name of the image attachment. mimeType is the MIME type of the image. bytes is the binary content of the image.

Implementation

ImageFileAttachment({
  required super.name,
  required super.mimeType,
  required super.bytes,
}) : assert(Attachment._isImage(mimeType));