完整内容,请查看:http://www.zhdoc.net/android/reference/android/widget/SectionIndexer.html
SectionIndexer
public interface SectionIndexer
android.widget.SectionIndexer |
Interface that may implemented on Adapter
s to enable fast scrolling between sections of an AbsListView
.
可以在Adapter
上实现的接口,以便在AbsListView
的各section之间快速滚动。
A section is a group of list items that have something in common. For example, they may begin with the same letter or they may be songs from the same artist.
section是有共同之处的列表项一个组。例如:它们可能开始与相同的字母,也可能是同一名艺术家的曲目。
ExpandableListAdapter
s that consider groups and sections as synonymous should account for collapsed groups and return an appropriate section/position.
ExpandableListAdapter
将组和section视为相同的,其用于已折叠的组,并返回适当的section/位置。
See also:
另请参考:
摘要
Public方法 | |
---|---|
abstract int | getPositionForSection(int sectionIndex) Given the index of a section within the array of section objects, returns the starting position of that section within the adapter. |
abstract int | getSectionForPosition(int position) Given a position within the adapter, returns the index of the corresponding section within the array of section objects. |
abstract Object[] | getSections() Returns an array of objects representing sections of the list. |
Public方法
getPositionForSection
int getPositionForSection (int sectionIndex)
Given the index of a section within the array of section objects, returns the starting position of that section within the adapter.
指定section对象的数组中的section索引,返回适配器中section的起始位置。