In Room there are approaches that could be used to define the relations between the entities:
- @Embedded (nested objects)
- @foreignkey
- @relation
In test should have been using relationship instead of two sequential request and foreach to bind a library to a book. My simple read results with foreach are about 400ms comparing to using @Embedded relationship they are 30ms.
In Room there are approaches that could be used to define the relations between the entities:
In test should have been using relationship instead of two sequential request and foreach to bind a library to a book. My simple read results with foreach are about 400ms comparing to using @Embedded relationship they are 30ms.