fromMap static method
Construct from the Map returned by MethodChannel.
Implementation
static TXTrackInfo fromMap(Map map) {
final info = TXTrackInfo(
(map['name'] as String?) ?? '',
(map['trackIndex'] as int?) ?? -1,
(map['trackType'] as int?) ?? TX_VOD_MEDIA_TRACK_TYPE_UNKNOW,
);
info.isSelected = (map['isSelected'] as bool?) ?? false;
info.isExclusive = (map['isExclusive'] as bool?) ?? true;
info.isInternal = (map['isInternal'] as bool?) ?? true;
return info;
}