Reference:Android.database.CursorWindow

From Triled Wiki

Jump to: navigation, search


android.database
public class android.database.CursorWindow

java.lang.Object
android.database.CursorWindow Parcelable

A buffer containing multiple cursor rows.

Contents

[edit] Summary

[edit] Constants

      Value  
Creator   CREATOR        

[edit] Public Constructors

          CursorWindow (boolean localWindow)
Creates a new empty window.

[edit] Public Methods

        void  clear ()
Clears out the existing contents of the window, making it safe to reuse for new data.
        void  close ()
Cleans up the native resources associated with the window.
        void  finalize ()
Called by the virtual machine when there are no longer any (non-weak) references to the receiver.
        double  getDouble (int row, int column)
Returns a double for the given field.
        float  getFloat (int row, int column)
Returns a float for the given field.
        int  getInt (int row, int column)
Returns an int for the given field.
        long  getLong (int row, int column)
Returns a long for the given field.
        int  getNumRows ()
Returns the number of rows in this window.
        short  getShort (int row, int column)
Returns a short for the given field.
        int  getStartPosition ()
Returns the starting position of this window within the entire Cursor's result set.
        String   getString (int row, int column)
Returns a String for the given field.
        boolean  isNull (int row, int column)
Returns true if given field is NULL.
      static  CursorWindow   newFromParcel (Parcel p)
        void  writeToParcel (Parcel dest)

[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.os.Parcelable

writeToParcel

[edit] Details

[edit] Constants

[edit] public static final Creator CREATOR

[edit] Public Constructors

[edit] public CursorWindow(boolean localWindow)

Creates a new empty window.

Parameters

localWindow true if this window will be used in this process only

[edit] Public Methods

[edit] public void clear()

Clears out the existing contents of the window, making it safe to reuse for new data. Note that the number of columns in the window may NOT change across a call to clear().

[edit] public void close()

Cleans up the native resources associated with the window.

[edit] public void finalize()

Called by the virtual machine when there are no longer any (non-weak) references to the receiver. Subclasses can use this facility to guarantee that any associated resources are cleaned up before the receiver is garbage collected. Uncaught exceptions which are thrown during the running of the method cause it to terminate immediately, but are otherwise ignored.

Note: The virtual machine assumes that the implementation in class Object is empty.

[edit] public double getDouble(int row, int column)

Returns a double for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • a double value for the given field

[edit] public float getFloat(int row, int column)

Returns a float for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • a float value for the given field

[edit] public int getInt(int row, int column)

Returns an int for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • an int value for the given field

[edit] public long getLong(int row, int column)

Returns a long for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • a long value for the given field

[edit] public int getNumRows()

Returns the number of rows in this window.

Returns

  • the number of rows in this window.

[edit] public short getShort(int row, int column)

Returns a short for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • a short value for the given field

[edit] public int getStartPosition()

Returns the starting position of this window within the entire Cursor's result set.

Returns

  • the starting position of this window within the entire Cursor's result set.

[edit] public String getString(int row, int column)

Returns a String for the given field.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • a String value for the given field

[edit] public boolean isNull(int row, int column)

Returns true if given field is NULL.

Parameters

row the row to read from, 0 being the first row in the window
column the column to read from

Returns

  • true if given field is NULL

[edit] public static CursorWindow newFromParcel(Parcel p)

[edit] public void writeToParcel(Parcel dest)

[edit] References

Personal tools