public class RoboCursor extends BaseCursor
Robolectric implementation of Cursor
.
Modifier and Type | Field and Description |
---|---|
protected java.util.List<java.lang.String> |
columnNames |
java.lang.String[] |
projection |
protected java.lang.Object[][] |
results |
java.lang.String |
selection |
java.lang.String[] |
selectionArgs |
java.lang.String |
sortOrder |
android.net.Uri |
uri |
Constructor and Description |
---|
RoboCursor() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
byte[] |
getBlob(int columnIndex) |
boolean |
getCloseWasCalled() |
int |
getColumnCount() |
int |
getColumnIndex(java.lang.String columnName) |
int |
getColumnIndexOrThrow(java.lang.String columnName) |
java.lang.String |
getColumnName(int index) |
java.lang.String[] |
getColumnNames() |
int |
getCount() |
double |
getDouble(int columnIndex) |
android.os.Bundle |
getExtras() |
float |
getFloat(int columnIndex) |
int |
getInt(int columnIndex) |
long |
getLong(int columnIndex) |
int |
getPosition() |
short |
getShort(int columnIndex) |
java.lang.String |
getString(int columnIndex) |
int |
getType(int columnIndex) |
boolean |
isAfterLast() |
boolean |
isBeforeFirst() |
boolean |
isClosed() |
boolean |
isFirst() |
boolean |
isLast() |
boolean |
isNull(int columnIndex) |
boolean |
move(int offset) |
boolean |
moveToFirst() |
boolean |
moveToLast() |
boolean |
moveToNext() |
boolean |
moveToPosition(int position) |
boolean |
moveToPrevious() |
void |
setColumnNames(java.util.List<java.lang.String> columnNames) |
void |
setExtras(android.os.Bundle extras) |
void |
setQuery(android.net.Uri uri,
java.lang.String[] projection,
java.lang.String selection,
java.lang.String[] selectionArgs,
java.lang.String sortOrder) |
void |
setResults(java.lang.Object[][] results) |
copyStringToBuffer, deactivate, getNotificationUri, getWantsAllOnMoveCalls, registerContentObserver, registerDataSetObserver, requery, respond, setNotificationUri, unregisterContentObserver, unregisterDataSetObserver
public android.net.Uri uri
public java.lang.String[] projection
public java.lang.String selection
public java.lang.String[] selectionArgs
public java.lang.String sortOrder
protected java.lang.Object[][] results
protected java.util.List<java.lang.String> columnNames
public void setQuery(android.net.Uri uri, java.lang.String[] projection, java.lang.String selection, java.lang.String[] selectionArgs, java.lang.String sortOrder)
setQuery
in class BaseCursor
public int getColumnIndexOrThrow(java.lang.String columnName) throws java.lang.IllegalArgumentException
getColumnIndexOrThrow
in interface android.database.Cursor
getColumnIndexOrThrow
in class BaseCursor
java.lang.IllegalArgumentException
public int getColumnIndex(java.lang.String columnName)
getColumnIndex
in interface android.database.Cursor
getColumnIndex
in class BaseCursor
public java.lang.String getString(int columnIndex)
getString
in interface android.database.Cursor
getString
in class BaseCursor
public short getShort(int columnIndex)
getShort
in interface android.database.Cursor
getShort
in class BaseCursor
public int getInt(int columnIndex)
getInt
in interface android.database.Cursor
getInt
in class BaseCursor
public long getLong(int columnIndex)
getLong
in interface android.database.Cursor
getLong
in class BaseCursor
public float getFloat(int columnIndex)
getFloat
in interface android.database.Cursor
getFloat
in class BaseCursor
public double getDouble(int columnIndex)
getDouble
in interface android.database.Cursor
getDouble
in class BaseCursor
public byte[] getBlob(int columnIndex)
getBlob
in interface android.database.Cursor
getBlob
in class BaseCursor
public int getType(int columnIndex)
getType
in interface android.database.Cursor
getType
in class BaseCursor
public boolean isNull(int columnIndex)
isNull
in interface android.database.Cursor
isNull
in class BaseCursor
public int getCount()
getCount
in interface android.database.Cursor
getCount
in class BaseCursor
public boolean moveToNext()
moveToNext
in interface android.database.Cursor
moveToNext
in class BaseCursor
public boolean moveToFirst()
moveToFirst
in interface android.database.Cursor
moveToFirst
in class BaseCursor
public boolean moveToPosition(int position)
moveToPosition
in interface android.database.Cursor
moveToPosition
in class BaseCursor
public void close()
close
in interface android.database.Cursor
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class BaseCursor
public int getColumnCount()
getColumnCount
in interface android.database.Cursor
getColumnCount
in class BaseCursor
public java.lang.String getColumnName(int index)
getColumnName
in interface android.database.Cursor
getColumnName
in class BaseCursor
public boolean isBeforeFirst()
isBeforeFirst
in interface android.database.Cursor
isBeforeFirst
in class BaseCursor
public boolean isAfterLast()
isAfterLast
in interface android.database.Cursor
isAfterLast
in class BaseCursor
public boolean isFirst()
isFirst
in interface android.database.Cursor
isFirst
in class BaseCursor
public boolean isLast()
isLast
in interface android.database.Cursor
isLast
in class BaseCursor
public int getPosition()
getPosition
in interface android.database.Cursor
getPosition
in class BaseCursor
public boolean move(int offset)
move
in interface android.database.Cursor
move
in class BaseCursor
public boolean moveToLast()
moveToLast
in interface android.database.Cursor
moveToLast
in class BaseCursor
public boolean moveToPrevious()
moveToPrevious
in interface android.database.Cursor
moveToPrevious
in class BaseCursor
public java.lang.String[] getColumnNames()
getColumnNames
in interface android.database.Cursor
getColumnNames
in class BaseCursor
public boolean isClosed()
isClosed
in interface android.database.Cursor
isClosed
in class BaseCursor
public android.os.Bundle getExtras()
getExtras
in interface android.database.Cursor
getExtras
in class BaseCursor
public void setExtras(android.os.Bundle extras)
setExtras
in interface android.database.Cursor
setExtras
in class BaseCursor
public void setColumnNames(java.util.List<java.lang.String> columnNames)
public void setResults(java.lang.Object[][] results)
public boolean getCloseWasCalled()