English | Site Directory

Android - An Open Handset Alliance Project

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 CursorWindows.

Known Direct Subclasses
Known Indirect Subclasses

Summary

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. 
Fields inherited from class android.database.AbstractCursor

Public Constructors

          AbstractWindowedCursor()

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.

Protected Methods

        void  checkPosition()
This function throws CursorIndexOutOfBoundsException if the cursor position is out of bounds.
Methods inherited from class android.database.AbstractCursor
Methods inherited from class java.lang.Object
Methods inherited from interface android.database.Cursor

Details

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.

Public Constructors

public AbstractWindowedCursor()

Public Methods

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).

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).

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).

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).

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).

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).

public boolean isNull(int columnIndex)

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

Protected Methods

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.
Build m5-rc15g - 14 May 2008 12:50