mirror of
https://github.com/antebudimir/tempus.git
synced 2026-01-03 19:01:39 +00:00
Add settings to pin and unpin playlist in toolbar menu
This commit is contained in:
parent
afe0e0751c
commit
e29b96d905
11 changed files with 170 additions and 5 deletions
|
|
@ -0,0 +1,24 @@
|
|||
package com.cappielloantonio.play.database.dao;
|
||||
|
||||
import androidx.lifecycle.LiveData;
|
||||
import androidx.room.Dao;
|
||||
import androidx.room.Delete;
|
||||
import androidx.room.Insert;
|
||||
import androidx.room.OnConflictStrategy;
|
||||
import androidx.room.Query;
|
||||
|
||||
import com.cappielloantonio.play.model.Playlist;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Dao
|
||||
public interface PlaylistDao {
|
||||
@Query("SELECT * FROM playlist")
|
||||
LiveData<List<Playlist>> getAll();
|
||||
|
||||
@Insert(onConflict = OnConflictStrategy.REPLACE)
|
||||
void insert(Playlist playlist);
|
||||
|
||||
@Delete
|
||||
void delete(Playlist playlist);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue