New Year Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: simple70

Google Developers Certification - Associate Android Developer (Kotlin and Java Exam) Associate-Android-Developer Question # 28 Topic 3 Discussion

Google Developers Certification - Associate Android Developer (Kotlin and Java Exam) Associate-Android-Developer Question # 28 Topic 3 Discussion

Associate-Android-Developer Exam Topic 3 Question 28 Discussion:
Question #: 28
Topic #: 3

What is demonstrated by the code below?

// RawDao.java

@Dao

interface RawDao {

@RawQuery

User getUserViaQuery(SupportSQLiteQuery query);

}

// Usage of RawDao

...

SimpleSQLiteQuery query =

new SimpleSQLiteQuery("SELECT * FROM UserWHERE id = ? LIMIT 1",

new Object[]{userId});

User user = rawDao.getUserViaQuery(query);

...


A.

A method in a Dao annotated class as a raw query method where you can pass the query as a

SupportSQLiteQuery.


B.

A method in a Dao annotated class as a query method.


C.

A method in a RoomDatabase class as a query method.


Get Premium Associate-Android-Developer Questions

Contribute your Thoughts:


Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.