Skip to content

Instantly share code, notes, and snippets.

@AkshayChordiya
Last active October 22, 2017 12:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AkshayChordiya/55c6968940e0d22519fc6239d5abef38 to your computer and use it in GitHub Desktop.
Save AkshayChordiya/55c6968940e0d22519fc6239d5abef38 to your computer and use it in GitHub Desktop.
Create the database instance - Room
// Get instance
database = Room.databaseBuilder(context, AppDatabase::class.java, "app.db")
.build();
// Example Usage
val userDao = database.userDao()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment