querySongs method
Future<List<SongModel> >
querySongs({
- SongSortType? sortType,
- OrderType? orderType,
- UriType? uriType,
- bool? ignoreCase,
- String? path,
Used to return Songs Info based in SongModel.
Parameters:
orderTypeis used to define if order will be Ascending or Descending.sortTypeis used to define list sort.uriTypeis used to define if songs will be catch inEXTERNALorINTERNALstorage.ignoreCaseis used to define if sort will ignore the lowercase or not.pathis used to define where the songs will be 'queried'.
Important:
- If
orderTypeis null, will be set toASC_OR_SMALLER. - If
sortTypeis null, will be set toDEFAULT. - If
uriTypeis null, will be set toEXTERNAL. - If
ignoreCaseis null, will be set totrue. - If
pathis null, will be set to the default platformpath.
Platforms:
| Android | IOS | Web |
|---|---|---|
✔️ |
✔️ |
✔️ |
See more about platforms support
Implementation
Future<List<SongModel>> querySongs({
SongSortType? sortType,
OrderType? orderType,
UriType? uriType,
bool? ignoreCase,
String? path,
}) async {
return platform.querySongs(
sortType: sortType,
orderType: orderType,
uriType: uriType,
ignoreCase: ignoreCase,
path: path,
);
}