mirror of
https://github.com/antebudimir/tempus.git
synced 2026-01-03 19:01:39 +00:00
Implementation of download navigation for artists and albums
This commit is contained in:
parent
c5f39cf9ee
commit
86d46f7537
16 changed files with 98 additions and 53 deletions
|
|
@ -12,12 +12,18 @@ import java.util.List;
|
|||
|
||||
@Dao
|
||||
public interface DownloadDao {
|
||||
@Query("SELECT * FROM download")
|
||||
List<Download> getAll();
|
||||
@Query("SELECT * FROM download WHERE server=:server")
|
||||
LiveData<List<Download>> getAll(String server);
|
||||
|
||||
@Query("SELECT * FROM download WHERE server=:server LIMIT :size")
|
||||
LiveData<List<Download>> getSample(int size, String server);
|
||||
|
||||
@Query("SELECT * FROM download WHERE server=:server AND artistId=:artistId")
|
||||
LiveData<List<Download>> getAllFromArtist(String server, String artistId);
|
||||
|
||||
@Query("SELECT * FROM download WHERE server=:server AND albumId=:albumId")
|
||||
LiveData<List<Download>> getAllFromAlbum(String server, String albumId);
|
||||
|
||||
@Insert(onConflict = OnConflictStrategy.REPLACE)
|
||||
void insert(Download download);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue