4. It can be accessed by other applications through ContentProvider.
Correct Answer : Get Lastest Questions and Answer : Explanation: To create your custom content provider you have to define a class which extends android.content.ContentProvider. You must declare this class as content provider in the Android manifest file. The corresponding entry must specify the android:authorities attribute which allows identifying the content provider. This authority is the basis for the URI to access data and must be unique.
Your content provider must implement several methods, e.g. query(), insert(), update(), delete(), getType() and onCreate(). In case you do not support certain methods its good practice to throw an UnsupportedOperationException().
The query() method must return a Cursor object.
Question : When including a text file in your application to read from as a resource, what is the recommended location of such file?
Correct Answer : Get Lastest Questions and Answer : Explanation: raw/ Arbitrary files to save in their raw form. To open these resources with a raw InputStream, call Resources.openRawResource() with the resource ID, which is R.raw.filename.
However, if you need access to original file names and file hierarchy, you might consider saving some resources in the assets/ directory (instead of res/raw/). Files in assets/ are not given a resource ID, so you can read them only using AssetManager.
Question : Which of the following statements about DDMS is incorrect?
1. You can display a list of currently running threads and select one to check its stack trace.
2. You can use it to acquire screenshots of a terminal.
4. You can do simulations of network zone speed and bandwidth limitations.
Correct Answer : Get Lastest Questions and Answer : Explanation: Android Studio includes a debugging tool called the Dalvik Debug Monitor Server (DDMS), which provides port-forwarding services, screen capture on the device, thread and heap information on the device, logcat, process, and radio state information, incoming call and SMS spoofing, location data spoofing, and more. This page provides a modest discussion of DDMS features; it is not an exhaustive exploration of all the features and capabilities.