Reference:Android.database.AbstractWindowedCursor

From Triled Wiki

Jump to: navigation, search


android.database
public abstract class android.database.AbstractWindowedCursor

java.lang.Object
android.database.AbstractCursor Cursor
android.database.AbstractWindowedCursor
A base class for Cursors that store their data in CursorWindow s.

Contents

[edit] Known Direct Subclasses
SQLiteCursor
[edit] Known Indirect Subclasses

DatabaseContentProvider.DcpCursor

[edit] Summary

[edit] Fields

protected      CursorWindow   mWindow   This needs be updated in onMove(int, int) by subclasses, and needs to be set to NULL when the contents of the cursor change.  

[edit] Fields inherited from class android.database.AbstractCursor

mContentResolver, mCurrentRowID, mPos, mRowIdColumnIndex, mUpdatedRows

[edit] Public Constructors

          AbstractWindowedCursor ()

[edit] Public Methods

        double  getDouble (int columnIndex)
Returns the value of the requested column as a double.
        float  getFloat (int columnIndex)
Returns the value of the requested column as a float.
        int  getInt (int columnIndex)
Returns the value of the requested column as an int.
        long  getLong (int columnIndex)
Returns the value of the requested column as a long.
        short  getShort (int columnIndex)
Returns the value of the requested column as a short.
        String   getString (int columnIndex)
Returns the value of the requested column as a String.
        boolean  isNull (int columnIndex)
Returns true if the value in the indicated column is null.

[edit] Protected Methods

        void  checkPosition ()
This function throws CursorIndexOutOfBoundsException if the cursor position is out of bounds.

[edit] Methods inherited from class android.database.AbstractCursor
abortUpdates, checkPosition, close, >)">commitUpdates, commitUpdates, count, deactivate, deleteRow, finalize, first, getColumnIndex, getColumnName, getColumnNames, getDouble, getExtras, getFloat, getInt, getLong, getShort, getString, getUpdatedField, getWantsAllOnMoveCalls, hasUpdates, isAfterLast, isBeforeFirst, isFieldUpdated, isFirst, isLast, isNull, last, move, moveTo, next, onChange, onMove, position, prev, registerContentObserver, registerDataSetObserver, requery, respond, setNotificationUri, supportsUpdates, unregisterContentObserver, unregisterDataSetObserver, update, updateDouble, updateFloat, updateInt, updateLong, updateShort, updateString, updateToNull
[edit] Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
[edit] Methods inherited from interface android.database.Cursor

abortUpdates, close, >)">commitUpdates, commitUpdates, count, deactivate, deleteRow, first, getColumnIndex, getColumnName, getColumnNames, getDouble, getExtras, getFloat, getInt, getLong, getShort, getString, getWantsAllOnMoveCalls, hasUpdates, isAfterLast, isBeforeFirst, isFirst, isLast, isNull, last, move, moveTo, next, position, prev, registerContentObserver, registerDataSetObserver, requery, respond, setNotificationUri, supportsUpdates, unregisterContentObserver, unregisterDataSetObserver, updateDouble, updateFloat, updateInt, updateLong, updateShort, updateString, updateToNull

[edit] Details

[edit] Fields

[edit] protected CursorWindow mWindow

This needs be updated in onMove(int, int) by subclasses, and needs to be set to NULL when the contents of the cursor change.

[edit] Public Constructors

[edit] public AbstractWindowedCursor()

[edit] Public Methods

[edit] public double getDouble(int columnIndex)

Returns the value of the requested column as a double.

If the native content of that column is not numeric the result will be the result of passing the column value to Double.valueOf(x).

[edit] public float getFloat(int columnIndex)

Returns the value of the requested column as a float.

If the native content of that column is not numeric the result will be the result of passing the column value to Float.valueOf(x).

[edit] public int getInt(int columnIndex)

Returns the value of the requested column as an int.

If the native content of that column is not numeric the result will be the result of passing the column value to Integer.valueOf(x).

[edit] public long getLong(int columnIndex)

Returns the value of the requested column as a long.

If the native content of that column is not numeric the result will be the result of passing the column value to Long.valueOf(x).

[edit] public short getShort(int columnIndex)

Returns the value of the requested column as a short.

If the native content of that column is not numeric the result will be the result of passing the column value to Short.valueOf(x).

[edit] public String getString(int columnIndex)

Returns the value of the requested column as a String.

If the native content of that column is not text the result will be the result of passing the column value to String.valueOf(x).

[edit] public boolean isNull(int columnIndex)

Returns true if the value in the indicated column is null.

[edit] Protected Methods

[edit] protected void checkPosition()

This function throws CursorIndexOutOfBoundsException if the cursor position is out of bounds. Subclass implementations of the get functions should call this before attempting to retrieve data.

[edit] References

Personal tools