IosMediaTrack.fromMap constructor
IosMediaTrack.fromMap(
- Map json
Creates an IosMediaTrack from a Map representation, typically from platform channels.
The json
map should contain keys matching the expected track properties.
Implementation
factory IosMediaTrack.fromMap(Map json) {
return IosMediaTrack(
trackContentType: json['content_type'],
trackId: json['id'],
type: TrackType.values[json['type']],
language: Rfc5646Language.fromMap(json['language_code']),
name: json['name'],
subtype: json['subtype'] != null
? TextTrackType.values[json['subtype']]
: null,
trackContentId: json['content_id'],
customData: json['custom_data'],
);
}