Created
June 3, 2017 04:34
-
-
Save manijshrestha/a3310dcf8e9fcc8aaa171c756dab52f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Dao interface TaskDao { | |
@Query("select * from task") | |
fun getAllTasks(): List<Task> | |
@Query("select * from task where id = :p0") | |
fun findTaskById(id: Long): Task | |
@Insert(onConflict = REPLACE) | |
fun insertTask(task: Task) | |
@Update(onConflict = REPLACE) | |
fun updateTask(task: Task) | |
@Delete | |
fun deleteTask(task: Task) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment