MediaItem class

Media item for inline use within climbs Matches the CLDF media.schema.json structure

Annotations
  • @JsonSerializable.new(includeIfNull: false)

Constructors

MediaItem({required MediaType type, required String path, String? assetId, String? thumbnailPath, MediaSource? source, MediaDesignation? designation, String? caption, String? timestamp, Map<String, dynamic>? metadata})
Creates a new MediaItem instance
MediaItem.fromJson(Map<String, dynamic> json)
Creates a MediaItem from JSON
factory

Properties

assetId String?
Asset ID for cloud/library stored media
final
caption String?
User-provided description or caption
final
designation MediaDesignation?
Purpose or type of media content
final
hashCode int
The hash code for this object.
no setterinherited
metadata Map<String, dynamic>?
Additional metadata
final
path String
Primary path/URL to the media file
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
source MediaSource?
Source of the media
final
thumbnailPath String?
Path to thumbnail (for performance)
final
timestamp String?
When the media was created or taken
final
type MediaType
Media type
final

Methods

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

Operators

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