queryAudiosWith method
Future<List<SongModel> >
queryAudiosWith({
- required AudiosFrom from,
- required int fromId,
- SongSortType sortType = SongSortType.title,
- OrderType orderType = OrderType.asc,
override
Implementation
@override
Future<List<SongModel>> queryAudiosWith({
required AudiosFrom from,
required int fromId,
SongSortType sortType = SongSortType.title,
OrderType orderType = OrderType.asc,
}) async {
final List<dynamic>? raw = await methodChannel
.invokeListMethod<dynamic>('queryAudiosWith', {
'from': from.index,
'fromId': fromId,
'sortType': sortType.index,
'orderType': orderType.index,
});
return (raw ?? [])
.map((e) => SongModel.fromMap(e as Map<dynamic, dynamic>))
.toList();
}