am 242fa0eb: am ce3b35a7: Merge "bug:3398527 return List insttead of ArrayList from public API" into honeycomb
* commit '242fa0eb73d555eb025c39cf212030f00cb53cb4': bug:3398527 return List insttead of ArrayList from public API
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
package android.database;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import android.database.sqlite.SQLiteDatabase;
|
||||
import android.database.sqlite.SQLiteException;
|
||||
@@ -65,7 +65,7 @@ public final class DefaultDatabaseErrorHandler implements DatabaseErrorHandler {
|
||||
return;
|
||||
}
|
||||
|
||||
ArrayList<Pair<String, String>> attachedDbs = null;
|
||||
List<Pair<String, String>> attachedDbs = null;
|
||||
try {
|
||||
// Close the database, which will cause subsequent operations to fail.
|
||||
// before that, get the attached database list first.
|
||||
|
||||
@@ -40,6 +40,7 @@ import dalvik.system.BlockGuard;
|
||||
import java.io.File;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.LinkedHashMap;
|
||||
@@ -2504,7 +2505,7 @@ public class SQLiteDatabase extends SQLiteClosable {
|
||||
String lastnode = path.substring((indx != -1) ? ++indx : 0);
|
||||
|
||||
// get list of attached dbs and for each db, get its size and pagesize
|
||||
ArrayList<Pair<String, String>> attachedDbs = db.getAttachedDbs();
|
||||
List<Pair<String, String>> attachedDbs = db.getAttachedDbs();
|
||||
if (attachedDbs == null) {
|
||||
continue;
|
||||
}
|
||||
@@ -2560,7 +2561,7 @@ public class SQLiteDatabase extends SQLiteClosable {
|
||||
* @return ArrayList of pairs of (database name, database file path) or null if the database
|
||||
* is not open.
|
||||
*/
|
||||
public ArrayList<Pair<String, String>> getAttachedDbs() {
|
||||
public List<Pair<String, String>> getAttachedDbs() {
|
||||
if (!isOpen()) {
|
||||
return null;
|
||||
}
|
||||
@@ -2613,7 +2614,7 @@ public class SQLiteDatabase extends SQLiteClosable {
|
||||
*/
|
||||
public boolean isDatabaseIntegrityOk() {
|
||||
verifyDbIsOpen();
|
||||
ArrayList<Pair<String, String>> attachedDbs = null;
|
||||
List<Pair<String, String>> attachedDbs = null;
|
||||
try {
|
||||
attachedDbs = getAttachedDbs();
|
||||
if (attachedDbs == null) {
|
||||
|
||||
Reference in New Issue
Block a user