我正在尝试为我正在编写的小游戏应用程序制作拖放列表.
列表中有6个条目.但是我添加的库需要一个与DB对话的Cursor对象.这对我的情况来说太过分了.
有没有办法创建一个基于基于内存的数据结构的Cursor对象,如数组?有没有办法可以使用硬编码数组作为我的光标?
谢谢
Tri*_*mon 52
String[] columns = new String[] { "_id", "item", "description" };
MatrixCursor matrixCursor= new MatrixCursor(columns);
startManagingCursor(matrixCursor);
matrixCursor.addRow(new Object[] { 1, "Item A", "...." });
SimpleCursorAdapter adapter = 
        new SimpleCursorAdapter(this, R.layout.layout_row, matrixCursor, ...);
setListAdapter(adapter);
| 归档时间: | 
 | 
| 查看次数: | 17482 次 | 
| 最近记录: |