ListRow


public class ListRow extends Row


A Row composed of a optional HeaderItem, and an ObjectAdapter describing the items in the list.

Summary

Public constructors

ListRow(HeaderItem header, ObjectAdapter adapter)
ListRow(long id, HeaderItem header, ObjectAdapter adapter)

Public methods

final ObjectAdapter

Returns the ObjectAdapter that represents a list of objects.

CharSequence

Returns content description for the ListRow.

void
setContentDescription(CharSequence contentDescription)

Explicitly set content description for the ListRow, getContentDescription will ignore values from HeaderItem.

Inherited methods

From androidx.leanback.widget.Row
final HeaderItem

Returns the HeaderItem that represents metadata for the row.

final long

Returns a unique identifier for this row.

boolean

Returns true if this Row can be rendered in a visible row view, false otherwise.

final void

Sets the HeaderItem that represents metadata for the row.

final void
setId(long id)

Sets the id for this row.

Public constructors

ListRow

Added in 1.1.0
public ListRow(ObjectAdapter adapter)

ListRow

Added in 1.1.0
public ListRow(HeaderItem header, ObjectAdapter adapter)

ListRow

Added in 1.1.0
public ListRow(long id, HeaderItem header, ObjectAdapter adapter)

Public methods

getAdapter

Added in 1.1.0
public final ObjectAdapter getAdapter()

Returns the ObjectAdapter that represents a list of objects.

getContentDescription

Added in 1.1.0
public CharSequence getContentDescription()

Returns content description for the ListRow. By default it returns getContentDescription or getName, unless setContentDescription was explicitly called.

Returns
CharSequence

Content description for the ListRow.

setContentDescription

Added in 1.1.0
public void setContentDescription(CharSequence contentDescription)

Explicitly set content description for the ListRow, getContentDescription will ignore values from HeaderItem.

Parameters
CharSequence contentDescription

Content description sets on the ListRow.