import '../models/album_model.dart'; import '../models/song_model.dart'; abstract class MusicDataSource { Future> getAlbums(); Future albumExists(AlbumModel albumModel); /// Insert album into the database. Return the ID of the inserted album. Future insertAlbum(AlbumModel albumModel); Future> getSongs(); Future> getSongsFromAlbum(AlbumModel album); Future songExists(SongModel songModel); Future insertSong(SongModel songModel); Future resetAlbumsPresentFlag(); /// Get an AlbumModel with the matching title and artist. Returns null if there is none. Future getAlbumByTitleArtist(String title, String artist); Future flagAlbumPresent(AlbumModel albumModel); Future removeNonpresentAlbums(); Future resetSongsPresentFlag(); Future getSongByPath(String path); Future getSongByTitleAlbumArtist( String title, String album, String artist); Future flagSongPresent(SongModel songModel); Future removeNonpresentSongs(); }