mirror of
https://github.com/SimpleMobileTools/Simple-Notes.git
synced 2025-06-05 17:00:23 +02:00
moving more db related functions to Room
This commit is contained in:
@ -11,6 +11,9 @@ interface NotesDao {
|
||||
@Query("SELECT * FROM notes WHERE id = :id")
|
||||
fun getNoteWithId(id: Int): Note?
|
||||
|
||||
@Query("SELECT id FROM notes WHERE path = :path")
|
||||
fun getNoteIdWithPath(path: String): Long?
|
||||
|
||||
@Insert(onConflict = OnConflictStrategy.REPLACE)
|
||||
fun insertOrUpdate(note: Note): Long
|
||||
|
||||
|
Reference in New Issue
Block a user