Android Networking Flashcards
6 cards from real Android Development practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 6 Android Networking flashcards as text
Which library is commonly used for type-safe HTTP client calls in Android?
Answer: Retrofit
Retrofit turns HTTP API calls into Kotlin/Java interfaces with annotations, providing type-safe REST client functionality.
What annotation is used in Retrofit to define a GET HTTP request?
Answer: @GET
@GET annotates a Retrofit interface method to indicate it should make an HTTP GET request to the specified URL path.
Which class in OkHttp is used to intercept and observe HTTP calls?
Answer: Interceptor
OkHttp's Interceptor interface allows you to observe, modify, or short-circuit HTTP requests and responses.
What permission is required for an Android app to access the internet?
Answer: android.permission.INTERNET
The android.permission.INTERNET permission must be declared in AndroidManifest.xml for an app to make network requests.
Which Retrofit converter factory parses JSON responses using Gson?
Answer: GsonConverterFactory
GsonConverterFactory is added to a Retrofit.Builder to enable automatic serialization and deserialization of JSON using Gson.
What does the term REST stand for in the context of Android networking?
Answer: Representational State Transfer
REST (Representational State Transfer) is an architectural style for building scalable web services using standard HTTP methods.