resolve merge conflicts of b41f50dfd0 to pi-dev-plus-aosp
Bug: None Test: I solemnly swear I tested this conflict resolution. Merged-In: I2bcc7f0eee31a1775dd7a5dd0f291d0d37bc1292 Change-Id: I227ce12b7419ce8541a362f98adc50965b779c3b
This commit is contained in:
@@ -1772,56 +1772,9 @@ Landroid/content/UndoOperation;-><init>(Landroid/content/UndoOwner;)V
|
||||
Landroid/content/UndoOperation;-><init>(Landroid/os/Parcel;Ljava/lang/ClassLoader;)V
|
||||
Landroid/content/UriMatcher;->mChildren:Ljava/util/ArrayList;
|
||||
Landroid/content/UriMatcher;->mText:Ljava/lang/String;
|
||||
Landroid/database/AbstractCursor;->mExtras:Landroid/os/Bundle;
|
||||
Landroid/database/AbstractCursor;->mNotifyUri:Landroid/net/Uri;
|
||||
Landroid/database/AbstractWindowedCursor;->clearOrCreateWindow(Ljava/lang/String;)V
|
||||
Landroid/database/AbstractWindowedCursor;->closeWindow()V
|
||||
Landroid/database/AbstractWindowedCursor;->onDeactivateOrClose()V
|
||||
Landroid/database/ContentObserver;->releaseContentObserver()Landroid/database/IContentObserver;
|
||||
Landroid/database/CursorWindow;->mWindowPtr:J
|
||||
Landroid/database/CursorWindow;->printStats()Ljava/lang/String;
|
||||
Landroid/database/CursorWindow;->sCursorWindowSize:I
|
||||
Landroid/database/CursorWindow;->sWindowToPidMap:Landroid/util/LongSparseArray;
|
||||
Landroid/database/CursorWrapper;->mCursor:Landroid/database/Cursor;
|
||||
Landroid/database/DatabaseUtils;->cursorPickFillWindowStartPosition(II)I
|
||||
Landroid/database/DatabaseUtils;->getTypeOfObject(Ljava/lang/Object;)I
|
||||
Landroid/database/IContentObserver$Stub;-><init>()V
|
||||
Landroid/database/IContentObserver$Stub;->asInterface(Landroid/os/IBinder;)Landroid/database/IContentObserver;
|
||||
Landroid/database/IContentObserver;->onChange(ZLandroid/net/Uri;I)V
|
||||
Landroid/database/MatrixCursor;->data:[Ljava/lang/Object;
|
||||
Landroid/database/MatrixCursor;->get(I)Ljava/lang/Object;
|
||||
Landroid/database/MatrixCursor;->rowCount:I
|
||||
Landroid/database/sqlite/DatabaseObjectNotClosedException;-><init>()V
|
||||
Landroid/database/sqlite/SQLiteClosable;->mReferenceCount:I
|
||||
Landroid/database/sqlite/SQLiteCursor;->fillWindow(I)V
|
||||
Landroid/database/sqlite/SQLiteCursor;->mEditTable:Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteCursor;->mQuery:Landroid/database/sqlite/SQLiteQuery;
|
||||
Landroid/database/sqlite/SQLiteCustomFunction;->dispatchCallback([Ljava/lang/String;)V
|
||||
Landroid/database/sqlite/SQLiteCustomFunction;->name:Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteCustomFunction;->numArgs:I
|
||||
Landroid/database/sqlite/SQLiteDatabase;->beginTransaction(Landroid/database/sqlite/SQLiteTransactionListener;Z)V
|
||||
Landroid/database/sqlite/SQLiteDatabase;->collectDbStats(Ljava/util/ArrayList;)V
|
||||
Landroid/database/sqlite/SQLiteDatabase;->CONFLICT_VALUES:[Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->getActiveDatabases()Ljava/util/ArrayList;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->getThreadSession()Landroid/database/sqlite/SQLiteSession;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->mConfigurationLocked:Landroid/database/sqlite/SQLiteDatabaseConfiguration;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->mConnectionPoolLocked:Landroid/database/sqlite/SQLiteConnectionPool;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->mThreadSession:Ljava/lang/ThreadLocal;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->openDatabase(Ljava/lang/String;Landroid/database/sqlite/SQLiteDatabase$OpenParams;)Landroid/database/sqlite/SQLiteDatabase;
|
||||
Landroid/database/sqlite/SQLiteDatabase;->reopenReadWrite()V
|
||||
Landroid/database/sqlite/SQLiteDatabaseConfiguration;->maxSqlCacheSize:I
|
||||
Landroid/database/sqlite/SQLiteOpenHelper;->mName:Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteProgram;->mBindArgs:[Ljava/lang/Object;
|
||||
Landroid/database/sqlite/SQLiteProgram;->mSql:Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteQueryBuilder;->computeProjection([Ljava/lang/String;)[Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteQueryBuilder;->mDistinct:Z
|
||||
Landroid/database/sqlite/SQLiteQueryBuilder;->mTables:Ljava/lang/String;
|
||||
Landroid/database/sqlite/SQLiteQueryBuilder;->mWhereClause:Ljava/lang/StringBuilder;
|
||||
Landroid/database/sqlite/SQLiteSession;->beginTransaction(ILandroid/database/sqlite/SQLiteTransactionListener;ILandroid/os/CancellationSignal;)V
|
||||
Landroid/database/sqlite/SQLiteStatement;-><init>(Landroid/database/sqlite/SQLiteDatabase;Ljava/lang/String;[Ljava/lang/Object;)V
|
||||
Landroid/database/sqlite/SqliteWrapper;->checkSQLiteException(Landroid/content/Context;Landroid/database/sqlite/SQLiteException;)V
|
||||
Landroid/database/sqlite/SqliteWrapper;->delete(Landroid/content/Context;Landroid/content/ContentResolver;Landroid/net/Uri;Ljava/lang/String;[Ljava/lang/String;)I
|
||||
Landroid/database/sqlite/SqliteWrapper;->update(Landroid/content/Context;Landroid/content/ContentResolver;Landroid/net/Uri;Landroid/content/ContentValues;Ljava/lang/String;[Ljava/lang/String;)I
|
||||
Landroid/graphics/ColorMatrixColorFilter;->setColorMatrixArray([F)V
|
||||
Landroid/graphics/FontFamily;->mNativePtr:J
|
||||
Landroid/graphics/FontListParser;->parse(Ljava/io/InputStream;)Landroid/text/FontConfig;
|
||||
|
||||
@@ -87,8 +87,6 @@ Landroid/content/pm/IPackageManager;->getApplicationInfo(Ljava/lang/String;II)La
|
||||
Landroid/content/pm/IPackageManager;->getHomeActivities(Ljava/util/List;)Landroid/content/ComponentName;
|
||||
Landroid/content/pm/IPackageManager;->getPackageInfo(Ljava/lang/String;II)Landroid/content/pm/PackageInfo;
|
||||
Landroid/content/pm/IPackageStatsObserver;->onGetStatsCompleted(Landroid/content/pm/PackageStats;Z)V
|
||||
Landroid/database/sqlite/SqliteWrapper;->insert(Landroid/content/Context;Landroid/content/ContentResolver;Landroid/net/Uri;Landroid/content/ContentValues;)Landroid/net/Uri;
|
||||
Landroid/database/sqlite/SqliteWrapper;->query(Landroid/content/Context;Landroid/content/ContentResolver;Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
|
||||
Landroid/hardware/location/IActivityRecognitionHardwareClient;->onAvailabilityChanged(ZLandroid/hardware/location/IActivityRecognitionHardware;)V
|
||||
Landroid/location/IGeocodeProvider;->getFromLocation(DDILandroid/location/GeocoderParams;Ljava/util/List;)Ljava/lang/String;
|
||||
Landroid/location/IGeocodeProvider;->getFromLocationName(Ljava/lang/String;DDDDILandroid/location/GeocoderParams;Ljava/util/List;)Ljava/lang/String;
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.ContentResolver;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
@@ -68,6 +69,7 @@ public abstract class AbstractCursor implements CrossProcessCursor {
|
||||
@Deprecated
|
||||
protected ContentResolver mContentResolver;
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private Uri mNotifyUri;
|
||||
|
||||
private final Object mSelfObserverLock = new Object();
|
||||
@@ -77,6 +79,7 @@ public abstract class AbstractCursor implements CrossProcessCursor {
|
||||
private final DataSetObservable mDataSetObservable = new DataSetObservable();
|
||||
private final ContentObservable mContentObservable = new ContentObservable();
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private Bundle mExtras = Bundle.EMPTY;
|
||||
|
||||
/* -------------------------------------------------------- */
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
|
||||
/**
|
||||
* A base class for Cursors that store their data in {@link CursorWindow}s.
|
||||
* <p>
|
||||
@@ -179,6 +181,7 @@ public abstract class AbstractWindowedCursor extends AbstractCursor {
|
||||
* Closes the cursor window and sets {@link #mWindow} to null.
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
protected void closeWindow() {
|
||||
if (mWindow != null) {
|
||||
mWindow.close();
|
||||
@@ -193,6 +196,7 @@ public abstract class AbstractWindowedCursor extends AbstractCursor {
|
||||
* @param name The window name.
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
protected void clearOrCreateWindow(String name) {
|
||||
if (mWindow == null) {
|
||||
mWindow = new CursorWindow(name);
|
||||
@@ -203,6 +207,7 @@ public abstract class AbstractWindowedCursor extends AbstractCursor {
|
||||
|
||||
/** @hide */
|
||||
@Override
|
||||
@UnsupportedAppUsage
|
||||
protected void onDeactivateOrClose() {
|
||||
super.onDeactivateOrClose();
|
||||
closeWindow();
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.net.Uri;
|
||||
import android.os.Handler;
|
||||
import android.os.UserHandle;
|
||||
@@ -59,6 +60,7 @@ public abstract class ContentObserver {
|
||||
*
|
||||
* {@hide}
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public IContentObserver releaseContentObserver() {
|
||||
synchronized (mLock) {
|
||||
final Transport oldTransport = mTransport;
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
package android.database;
|
||||
|
||||
import android.annotation.BytesLong;
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.res.Resources;
|
||||
import android.database.sqlite.SQLiteClosable;
|
||||
import android.database.sqlite.SQLiteException;
|
||||
@@ -45,12 +46,14 @@ public class CursorWindow extends SQLiteClosable implements Parcelable {
|
||||
private static final String STATS_TAG = "CursorWindowStats";
|
||||
|
||||
// This static member will be evaluated when first used.
|
||||
@UnsupportedAppUsage
|
||||
private static int sCursorWindowSize = -1;
|
||||
|
||||
/**
|
||||
* The native CursorWindow object pointer. (FOR INTERNAL USE ONLY)
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public long mWindowPtr;
|
||||
|
||||
private int mStartPos;
|
||||
@@ -744,6 +747,7 @@ public class CursorWindow extends SQLiteClosable implements Parcelable {
|
||||
dispose();
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private static final LongSparseArray<Integer> sWindowToPidMap = new LongSparseArray<Integer>();
|
||||
|
||||
private void recordNewWindow(int pid, long window) {
|
||||
@@ -765,6 +769,7 @@ public class CursorWindow extends SQLiteClosable implements Parcelable {
|
||||
}
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private String printStats() {
|
||||
StringBuilder buff = new StringBuilder();
|
||||
int myPid = Process.myPid();
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.ContentResolver;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
@@ -26,6 +27,7 @@ import android.os.Bundle;
|
||||
*/
|
||||
public class CursorWrapper implements Cursor {
|
||||
/** @hide */
|
||||
@UnsupportedAppUsage
|
||||
protected final Cursor mCursor;
|
||||
|
||||
/**
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.ContentValues;
|
||||
import android.content.Context;
|
||||
import android.content.OperationApplicationException;
|
||||
@@ -232,6 +233,7 @@ public class DatabaseUtils {
|
||||
* @return object value type
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public static int getTypeOfObject(Object obj) {
|
||||
if (obj == null) {
|
||||
return Cursor.FIELD_TYPE_NULL;
|
||||
@@ -760,6 +762,7 @@ public class DatabaseUtils {
|
||||
* the requested row.
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public static int cursorPickFillWindowStartPosition(
|
||||
int cursorPosition, int cursorWindowCapacity) {
|
||||
return Math.max(cursorPosition - cursorWindowCapacity / 3, 0);
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import java.util.ArrayList;
|
||||
|
||||
/**
|
||||
@@ -26,7 +27,9 @@ import java.util.ArrayList;
|
||||
public class MatrixCursor extends AbstractCursor {
|
||||
|
||||
private final String[] columnNames;
|
||||
@UnsupportedAppUsage
|
||||
private Object[] data;
|
||||
@UnsupportedAppUsage
|
||||
private int rowCount = 0;
|
||||
private final int columnCount;
|
||||
|
||||
@@ -61,6 +64,7 @@ public class MatrixCursor extends AbstractCursor {
|
||||
/**
|
||||
* Gets value at the given column for the current row.
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
private Object get(int column) {
|
||||
if (column < 0 || column >= columnCount) {
|
||||
throw new CursorIndexOutOfBoundsException("Requested column: "
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
|
||||
/**
|
||||
* An exception that indicates that garbage-collector is finalizing a database object
|
||||
* that is not explicitly closed
|
||||
@@ -25,6 +27,7 @@ public class DatabaseObjectNotClosedException extends RuntimeException {
|
||||
private static final String s = "Application did not close the cursor or database object " +
|
||||
"that was opened here";
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public DatabaseObjectNotClosedException() {
|
||||
super(s);
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import java.io.Closeable;
|
||||
|
||||
/**
|
||||
@@ -24,6 +25,7 @@ import java.io.Closeable;
|
||||
* This class implements a primitive reference counting scheme for database objects.
|
||||
*/
|
||||
public abstract class SQLiteClosable implements Closeable {
|
||||
@UnsupportedAppUsage
|
||||
private int mReferenceCount = 1;
|
||||
|
||||
/**
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.database.AbstractWindowedCursor;
|
||||
import android.database.CursorWindow;
|
||||
import android.database.DatabaseUtils;
|
||||
@@ -39,12 +40,14 @@ public class SQLiteCursor extends AbstractWindowedCursor {
|
||||
static final int NO_COUNT = -1;
|
||||
|
||||
/** The name of the table to edit */
|
||||
@UnsupportedAppUsage
|
||||
private final String mEditTable;
|
||||
|
||||
/** The names of the columns in the rows */
|
||||
private final String[] mColumns;
|
||||
|
||||
/** The query object for the cursor */
|
||||
@UnsupportedAppUsage
|
||||
private final SQLiteQuery mQuery;
|
||||
|
||||
/** The compiled query this cursor came from */
|
||||
@@ -139,6 +142,7 @@ public class SQLiteCursor extends AbstractWindowedCursor {
|
||||
return mCount;
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private void fillWindow(int requiredPos) {
|
||||
clearOrCreateWindow(getDatabase().getPath());
|
||||
try {
|
||||
|
||||
@@ -16,13 +16,17 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
|
||||
/**
|
||||
* Describes a custom SQL function.
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public final class SQLiteCustomFunction {
|
||||
@UnsupportedAppUsage
|
||||
public final String name;
|
||||
@UnsupportedAppUsage
|
||||
public final int numArgs;
|
||||
public final SQLiteDatabase.CustomFunction callback;
|
||||
|
||||
@@ -47,6 +51,7 @@ public final class SQLiteCustomFunction {
|
||||
|
||||
// Called from native.
|
||||
@SuppressWarnings("unused")
|
||||
@UnsupportedAppUsage
|
||||
private void dispatchCallback(String[] args) {
|
||||
callback.callback(args);
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ import android.annotation.IntDef;
|
||||
import android.annotation.IntRange;
|
||||
import android.annotation.NonNull;
|
||||
import android.annotation.Nullable;
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.app.ActivityManager;
|
||||
import android.content.ContentValues;
|
||||
import android.database.Cursor;
|
||||
@@ -91,6 +92,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
// Thread-local for database sessions that belong to this database.
|
||||
// Each thread has its own database session.
|
||||
// INVARIANT: Immutable.
|
||||
@UnsupportedAppUsage
|
||||
private final ThreadLocal<SQLiteSession> mThreadSession = ThreadLocal
|
||||
.withInitial(this::createSession);
|
||||
|
||||
@@ -124,12 +126,14 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
|
||||
// The database configuration.
|
||||
// INVARIANT: Guarded by mLock.
|
||||
@UnsupportedAppUsage
|
||||
private final SQLiteDatabaseConfiguration mConfigurationLocked;
|
||||
|
||||
// The connection pool for the database, null when closed.
|
||||
// The pool itself is thread-safe, but the reference to it can only be acquired
|
||||
// when the lock is held.
|
||||
// INVARIANT: Guarded by mLock.
|
||||
@UnsupportedAppUsage
|
||||
private SQLiteConnectionPool mConnectionPoolLocked;
|
||||
|
||||
// True if the database has attached databases.
|
||||
@@ -189,6 +193,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
*/
|
||||
public static final int CONFLICT_NONE = 0;
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private static final String[] CONFLICT_VALUES = new String[]
|
||||
{"", " OR ROLLBACK ", " OR ABORT ", " OR FAIL ", " OR IGNORE ", " OR REPLACE "};
|
||||
|
||||
@@ -399,6 +404,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
* @throws IllegalStateException if the thread does not yet have a session and
|
||||
* the database is not open.
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
SQLiteSession getThreadSession() {
|
||||
return mThreadSession.get(); // initialValue() throws if database closed
|
||||
}
|
||||
@@ -542,6 +548,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
beginTransaction(transactionListener, false);
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private void beginTransaction(SQLiteTransactionListener transactionListener,
|
||||
boolean exclusive) {
|
||||
acquireReference();
|
||||
@@ -729,6 +736,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
return openDatabase(path.getPath(), openParams);
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private static SQLiteDatabase openDatabase(@NonNull String path,
|
||||
@NonNull OpenParams openParams) {
|
||||
Preconditions.checkArgument(openParams != null, "OpenParams cannot be null");
|
||||
@@ -838,6 +846,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
* @see #isReadOnly()
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public void reopenReadWrite() {
|
||||
synchronized (mLock) {
|
||||
throwIfNotOpenLocked();
|
||||
@@ -2138,6 +2147,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
return dbStatsList;
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private void collectDbStats(ArrayList<DbStats> dbStatsList) {
|
||||
synchronized (mLock) {
|
||||
if (mConnectionPoolLocked != null) {
|
||||
@@ -2146,6 +2156,7 @@ public final class SQLiteDatabase extends SQLiteClosable {
|
||||
}
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private static ArrayList<SQLiteDatabase> getActiveDatabases() {
|
||||
ArrayList<SQLiteDatabase> databases = new ArrayList<SQLiteDatabase>();
|
||||
synchronized (sActiveDatabases) {
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Locale;
|
||||
import java.util.regex.Pattern;
|
||||
@@ -67,6 +68,7 @@ public final class SQLiteDatabaseConfiguration {
|
||||
*
|
||||
* Default is 25.
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public int maxSqlCacheSize;
|
||||
|
||||
/**
|
||||
|
||||
@@ -19,6 +19,7 @@ package android.database.sqlite;
|
||||
import android.annotation.IntRange;
|
||||
import android.annotation.NonNull;
|
||||
import android.annotation.Nullable;
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.Context;
|
||||
import android.database.DatabaseErrorHandler;
|
||||
import android.database.SQLException;
|
||||
@@ -52,6 +53,7 @@ public abstract class SQLiteOpenHelper {
|
||||
private static final String TAG = SQLiteOpenHelper.class.getSimpleName();
|
||||
|
||||
private final Context mContext;
|
||||
@UnsupportedAppUsage
|
||||
private final String mName;
|
||||
private final int mNewVersion;
|
||||
private final int mMinimumSupportedVersion;
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.database.DatabaseUtils;
|
||||
import android.os.CancellationSignal;
|
||||
|
||||
@@ -31,10 +32,12 @@ public abstract class SQLiteProgram extends SQLiteClosable {
|
||||
private static final String[] EMPTY_STRING_ARRAY = new String[0];
|
||||
|
||||
private final SQLiteDatabase mDatabase;
|
||||
@UnsupportedAppUsage
|
||||
private final String mSql;
|
||||
private final boolean mReadOnly;
|
||||
private final String[] mColumnNames;
|
||||
private final int mNumParameters;
|
||||
@UnsupportedAppUsage
|
||||
private final Object[] mBindArgs;
|
||||
|
||||
SQLiteProgram(SQLiteDatabase db, String sql, Object[] bindArgs,
|
||||
|
||||
@@ -18,6 +18,7 @@ package android.database.sqlite;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.annotation.Nullable;
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.ContentValues;
|
||||
import android.database.Cursor;
|
||||
import android.database.DatabaseUtils;
|
||||
@@ -49,8 +50,11 @@ public class SQLiteQueryBuilder
|
||||
Pattern.compile("\\s*\\d+\\s*(,\\s*\\d+\\s*)?");
|
||||
|
||||
private Map<String, String> mProjectionMap = null;
|
||||
@UnsupportedAppUsage
|
||||
private String mTables = "";
|
||||
@UnsupportedAppUsage
|
||||
private StringBuilder mWhereClause = null; // lazily created
|
||||
@UnsupportedAppUsage
|
||||
private boolean mDistinct;
|
||||
private SQLiteDatabase.CursorFactory mFactory;
|
||||
private boolean mStrict;
|
||||
@@ -763,6 +767,7 @@ public class SQLiteQueryBuilder
|
||||
return query.toString();
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
private String[] computeProjection(String[] projectionIn) {
|
||||
if (projectionIn != null && projectionIn.length > 0) {
|
||||
if (mProjectionMap != null) {
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.database.CursorWindow;
|
||||
import android.database.DatabaseUtils;
|
||||
import android.os.CancellationSignal;
|
||||
@@ -291,6 +292,7 @@ public final class SQLiteSession {
|
||||
* @see #yieldTransaction
|
||||
* @see #endTransaction
|
||||
*/
|
||||
@UnsupportedAppUsage
|
||||
public void beginTransaction(int transactionMode,
|
||||
SQLiteTransactionListener transactionListener, int connectionFlags,
|
||||
CancellationSignal cancellationSignal) {
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.os.ParcelFileDescriptor;
|
||||
|
||||
/**
|
||||
@@ -27,6 +28,7 @@ import android.os.ParcelFileDescriptor;
|
||||
* </p>
|
||||
*/
|
||||
public final class SQLiteStatement extends SQLiteProgram {
|
||||
@UnsupportedAppUsage
|
||||
SQLiteStatement(SQLiteDatabase db, String sql, Object[] bindArgs) {
|
||||
super(db, sql, bindArgs, null);
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
|
||||
package android.database.sqlite;
|
||||
|
||||
import android.annotation.UnsupportedAppUsage;
|
||||
import android.content.ContentResolver;
|
||||
import android.content.ContentValues;
|
||||
import android.content.Context;
|
||||
@@ -44,6 +45,7 @@ public final class SqliteWrapper {
|
||||
return e.getMessage().equals(SQLITE_EXCEPTION_DETAIL_MESSAGE);
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public static void checkSQLiteException(Context context, SQLiteException e) {
|
||||
if (isLowMemory(e)) {
|
||||
Toast.makeText(context, com.android.internal.R.string.low_memory,
|
||||
@@ -53,6 +55,7 @@ public final class SqliteWrapper {
|
||||
}
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public static Cursor query(Context context, ContentResolver resolver, Uri uri,
|
||||
String[] projection, String selection, String[] selectionArgs, String sortOrder) {
|
||||
try {
|
||||
@@ -73,6 +76,7 @@ public final class SqliteWrapper {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@UnsupportedAppUsage
|
||||
public static int update(Context context, ContentResolver resolver, Uri uri,
|
||||
ContentValues values, String where, String[] selectionArgs) {
|
||||
try {
|
||||
@@ -84,6 +88,7 @@ public final class SqliteWrapper {
|
||||
}
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public static int delete(Context context, ContentResolver resolver, Uri uri,
|
||||
String where, String[] selectionArgs) {
|
||||
try {
|
||||
@@ -95,6 +100,7 @@ public final class SqliteWrapper {
|
||||
}
|
||||
}
|
||||
|
||||
@UnsupportedAppUsage
|
||||
public static Uri insert(Context context, ContentResolver resolver,
|
||||
Uri uri, ContentValues values) {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user