Skip to content

Commit 7ec683b

Browse files
author
The Android Automerger
committed
Revert "Clean up CursorWindow code."
This reverts commit 3bc6bbc.
1 parent dd8f899 commit 7ec683b

File tree

8 files changed

+858
-815
lines changed

8 files changed

+858
-815
lines changed

core/java/android/database/CursorWindow.java

Lines changed: 366 additions & 426 deletions
Large diffs are not rendered by default.

core/java/android/database/CursorWindowAllocationException.java

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,17 @@
1818

1919
/**
2020
* This exception is thrown when a CursorWindow couldn't be allocated,
21-
* most probably due to memory not being available.
22-
*
23-
* @hide
21+
* most probably due to memory not being available
2422
*/
25-
public class CursorWindowAllocationException extends RuntimeException {
26-
public CursorWindowAllocationException(String description) {
23+
class CursorWindowAllocationException extends java.lang.RuntimeException
24+
{
25+
public CursorWindowAllocationException()
26+
{
27+
super();
28+
}
29+
30+
public CursorWindowAllocationException(String description)
31+
{
2732
super(description);
2833
}
2934
}

core/java/android/database/sqlite/SQLiteQuery.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public class SQLiteQuery extends SQLiteProgram {
7979
// if the start pos is not equal to 0, then most likely window is
8080
// too small for the data set, loading by another thread
8181
// is not safe in this situation. the native code will ignore maxRead
82-
int numRows = native_fill_window(window.mWindowPtr, window.getStartPosition(),
82+
int numRows = native_fill_window(window, window.getStartPosition(),
8383
mOffsetIndex, maxRead, lastPos);
8484
mDatabase.logTimeStat(mSql, timeStart);
8585
return numRows;
@@ -154,7 +154,7 @@ public void close() {
154154
compileAndbindAllArgs();
155155
}
156156

157-
private final native int native_fill_window(int windowPtr,
157+
private final native int native_fill_window(CursorWindow window,
158158
int startPos, int offsetParam, int maxRead, int lastPos);
159159

160160
private final native int native_column_count();

0 commit comments

Comments
 (0)