fileExtension property

String? get fileExtension

Returns the typical file extension for this artwork's MIME type.

This is a convenience method that returns the most common file extension for the artwork format, without the leading dot.

Returns null if the MIME type is not recognized.

Example:

final artwork = ArtworkData(mimeType: 'image/jpeg', ...);
print(artwork.fileExtension); // 'jpg'

Implementation

String? get fileExtension => mimeTypeEnum?.fileExtension;