queryMostPlayed method

Future<List<MostPlayedEntity>> queryMostPlayed({
  1. int limit = 50,
  2. bool reverse = false,
  3. RoomSortType? sortType,
})

Used to query all songs(entities) from most_played room.

Use checkIn to know if song exist on most_played room.

Parameters:

  • limit this will limit the amount of entities queried. Taking less time to run and giving a better performance.
  • reverse this will define if list return will be reversed or no.
  • sortType this will define the list sort type.

Important:

  • If limit is null, will be set to 50.
  • If reverse is null, will be set to false.
  • If sortType is null, will be set to key.

Return:

See too:

Implementation

Future<List<MostPlayedEntity>> queryMostPlayed({
  int limit = 50,
  bool reverse = false,
  RoomSortType? sortType,
}) async {
  return _MostPlayedDao().queryMostPlayed(
    limit,
    reverse,
    sortType,
  );
}