Questions
Question 1 Multiple Choice (Single Answer)
Which data type can be stored using shared preferences?
- Any data type
- Primitive data type
- Advance data type
- Option (2) and (3)
Question 2 Multiple Choice (Single Answer)
__________ method creates only one preference file for the activity.
- getSharedPreferences()
- getPreferences()
- Both (1) and (2)
- None of these
Question 3 Multiple Choice (Single Answer)
Shared preferences can use shared data
- between multiple applications
- for single application
- Both (1) and (2)
- None of these
Question 4 Multiple Choice (Single Answer)
Android by default supports
- SQLDatabase
- SQLite database
- access database
- android database
Question 5 Multiple Choice (Single Answer)
Shared preferences store data as
- hash map
- key–value pair
- built in database
- None of these
Question 6 Multiple Choice (Single Answer)
No permission is needed to store data in
- shared preferences
- internal storage
- external storage
- Both (1) and (2)
Question 7 Multiple Choice (Single Answer)
_________ class is used to implement SQLiteDatabase in android
- SQLiteHelper
- SQLiteDatabase
- SQLiteOpenHelper
- SQLiteConnector
Question 8 Multiple Choice (Single Answer)
SQLite is ________ type of database.
- network
- object–oriented
- relational
- None of these
Question 9 Multiple Choice (Single Answer)
OpenFileInput()method returns
- InputStream
- InputStreamReader
- FileInputstream
- StreamReader
Question 10 Multiple Choice (Single Answer)
OpenFileOutput()method is used to
- read data from file
- write data to file
- Both (1) and (2)
- None of these
Question 11 Multiple Choice (Single Answer)
getExternalStorageDirectory()method returns sdcard location that
- is same for all devices
- may vary for different devices
- is Mnt/sdcard
- None of these
Question 12 Multiple Choice (Single Answer)
SQLite database needs _________ connection.
- JDBC
- ODBC
- network
- no
Question 13 Multiple Choice (Single Answer)
execSQL() method of SQLiteDatabase is used to
- execute query
- update data
- insert data
- Both (2) and (3)
Question 14 Multiple Choice (Single Answer)
SQLite is written or developed using
- Android
- Java
- ANSI-C
- None of these
Question 15 Multiple Choice (Single Answer)
Which of the following statements is/are true?
(a) File(<path>) can return directory status.
(b) File(<file name>) can return file status.
- Both (a) and (b)
- Only (a)
- Only (b)
- None of these