DownloadAttachmentDto class

Constructors

DownloadAttachmentDto({required String base64FileContents, required String contentType, required int sizeBytes})
Returns a new DownloadAttachmentDto instance.

Properties

base64FileContents String
Base64 encoded string of attachment bytes. Decode the base64 encoded string to get the raw contents. If the file has a content type such as text/html you can read the contents directly by converting it to string using utf-8 encoding.
getter/setter pair
contentType String
Content type of attachment. Examples are image/png, application/msword, text/csv etc.
getter/setter pair
hashCode int
The hash code for this object.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sizeBytes int
Size in bytes of attachment content
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override

Static Methods

fromJson(dynamic value) DownloadAttachmentDto?
Returns a new DownloadAttachmentDto instance and imports its values from value if it's a Map, null otherwise.
listFromJson(dynamic json, {bool growable = false}) List<DownloadAttachmentDto>?
mapFromJson(dynamic json) Map<String, DownloadAttachmentDto>
mapListFromJson(dynamic json, {bool growable = false}) Map<String, List<DownloadAttachmentDto>>

Constants

requiredKeys → const Set<String>
The list of required keys that must be present in a JSON.