Skip to content

Instantly share code, notes, and snippets.

@jonathanrz
Created November 6, 2017 23:19
Show Gist options
  • Select an option

  • Save jonathanrz/53691ddbfc2ba746750ff9b438ae098c to your computer and use it in GitHub Desktop.

Select an option

Save jonathanrz/53691ddbfc2ba746750ff9b438ae098c to your computer and use it in GitHub Desktop.
@Dao
interface DataDao {
@Query("SELECT * FROM Data")
fun all(): List<Data>
@Insert(onConflict = OnConflictStrategy.REPLACE)
fun save(data: Data): Long
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment