Room Database Library
Room library is an abstraction layer on top of SQLite. Instead of using SQLite directly, Room simplifies the chores of setting up, configuration and interacting with the DB.
Let's have a quick overview.
There is 3 main components Room Database.
ENTITY
An entity represents a table in your app's database. Using annotation for every instance in the entity is among good practices.
DAO
Database Access Object(DAO) provides the methods that your app uses to retrieve, update, insert and delete in the database.
DATABASE CLASS
The DB class holds the database and is the main access point for the underlying connection to your app's database. The database class provides your app with instances of the DAOs associated with that DB.