ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 80 - Associate Android Developer discussion

Report
Export

What happens when you create a DAO method and annotate it with @Insert?

Example:

@Dao

public interface MyDao {

@Insert(onConflict = OnConflictStrategy.REPLACE) public void insertUsers(User... users); }

A.
Room generates an implementation that inserts all parameters into the database in a single transaction.
Answers
A.
Room generates an implementation that inserts all parameters into the database in a single transaction.
B.
Room modifies a set of entities, given as parameters, in the database. It uses a query that matches against the primary key of each entity.
Answers
B.
Room modifies a set of entities, given as parameters, in the database. It uses a query that matches against the primary key of each entity.
C.
Room removes a set of entities, given as parameters, from the database. It uses the primary keys to find the entities to delete.
Answers
C.
Room removes a set of entities, given as parameters, from the database. It uses the primary keys to find the entities to delete.
Suggested answer: A
asked 18/09/2024
Wilfried Wagener
36 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first