AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder


public final class AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder


Builder for creating CollectionItemInfoCompat objects.

Summary

Public constructors

Creates a new Builder.

Public methods

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat

Builds and returns a AccessibilityNodeInfo.CollectionItemInfo.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setColumnIndex(int columnIndex)

Sets the column index at which the item is located.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setColumnSpan(int columnSpan)

Sets the number of columns the item spans.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder

Sets the column title at which the item is located.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setHeading(boolean heading)

Sets the collection item is a heading.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setRowIndex(int rowIndex)

Sets the row index at which the item is located.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setRowSpan(int rowSpan)

Sets the number of rows the item spans.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder

Sets the row title at which the item is located.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setSelected(boolean selected)

Sets the collection item is selected.

@NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder
setSortDirection(int sortDirection)

Sets the sort direction for this item.

Public constructors

Builder

Added in 1.12.0
public Builder()

Creates a new Builder.

Public methods

setColumnIndex

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setColumnIndex(int columnIndex)

Sets the column index at which the item is located.

Parameters
int columnIndex

The column index

setColumnSpan

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setColumnSpan(int columnSpan)

Sets the number of columns the item spans.

Parameters
int columnSpan

The number of columns spans

setColumnTitle

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setColumnTitle(@Nullable String columnTitle)

Sets the column title at which the item is located.

Parameters
@Nullable String columnTitle

The column title

setHeading

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setHeading(boolean heading)

Sets the collection item is a heading.

Parameters
boolean heading

The heading state

setRowIndex

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setRowIndex(int rowIndex)

Sets the row index at which the item is located.

Parameters
int rowIndex

The row index

setRowSpan

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setRowSpan(int rowSpan)

Sets the number of rows the item spans.

Parameters
int rowSpan

The number of rows spans

setRowTitle

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setRowTitle(@Nullable String rowTitle)

Sets the row title at which the item is located.

Parameters
@Nullable String rowTitle

The row title

setSelected

Added in 1.12.0
public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setSelected(boolean selected)

Sets the collection item is selected.

Parameters
boolean selected

The number of rows spans

setSortDirection

public @NonNull AccessibilityNodeInfoCompat.CollectionItemInfoCompat.Builder setSortDirection(int sortDirection)

Sets the sort direction for this item.

Valid only if isHeading returns true. Indicates that collection content associated with this heading is presented in the indicated sort direction. It should only be called by accessibility providers. For accessibility services, see getSortDirection to query the current state.

Parameters
int sortDirection

the sort direction of this collection item info