Android7.0中文文档(API)-- ResourceCursorAdapter

ResourceCursorAdapter

public abstract class ResourceCursorAdapter
extends CursorAdapter

java.lang.Object
   ↳android.widget.BaseAdapter
    ↳android.widget.CursorAdapter
     ↳android.widget.ResourceCursorAdapter
已知的直接子类


An easy adapter that creates views defined in an XML file. You can specify the XML file that defines the appearance of the views.
一个简单的适配器,创建定义在一个XML文件中的视图。你可以指定XML文件来定义视图的外观。

摘要


继承常量

From class android.widget.CursorAdapter
From interface android.widget.Adapter

Public构造方法

ResourceCursorAdapter(Context context, int layout, Cursor c)

This constructor was deprecated in API level 11. This option is discouraged, as it results in Cursor queries being performed on the application's UI thread and thus can cause poor responsiveness or even Application Not Responding errors. As an alternative, use LoaderManager with a CursorLoader.
此常量在API level 11版本中被取消。这个选项已被删除,因为它会导致在应用程序UI线程上执行游标查询,从而导致糟糕的响应能力,甚至出现应用程序不响应错误。可以选择使用LoaderManagerCursorLoader

ResourceCursorAdapter(Context context, int layout, Cursor c, boolean autoRequery)

Constructor with default behavior as per CursorAdapter(Context, Cursor, boolean); it is recommended you not use this, but instead ResourceCursorAdapter(Context, int, Cursor, int).
具有默认行为的构造方法,如同CursorAdapter(Context, Cursor, boolean);不建议你使用此方法,而使用ResourceCursorAdapter(Context, int, Cursor, int)来替代。

ResourceCursorAdapter(Context context, int layout, Cursor c, int flags)

Standard constructor.
标准构造方法。

Public方法

ViewnewDropDownView(Context context, Cursor cursor, ViewGroup parent)

Makes a new drop down view to hold the data pointed to by cursor.
新建一个下拉视图,以容纳游标指向的数据。

ViewnewView(Context context, Cursor cursor, ViewGroup parent)

Inflates view(s) from the specified XML file.
从指定的XML文件加载(inflate)视图。

voidsetDropDownViewResource(int dropDownLayout)

Sets the layout resource of the drop down views.
设置下拉视图的布局资源。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值