# AccessibilityNodeInfoCompat.CollectionItemInfoCompat

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  
belongs to Maven artifact com.android.support:support-compat:28.0.0-alpha1  
Summary:[Methods](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#pubmethods)\|[Inherited Methods](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#inhmethods)\|[\[Expand All\]](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#)  

# AccessibilityNodeInfoCompat.CollectionItemInfoCompat

| This package is part of the Android[support library](https://developer.android.com/topic/libraries/support-library)which is no longer maintained. The support library has been superseded by[AndroidX](https://developer.android.com/jetpack/androidx)which is part of[Jetpack](https://developer.android.com/jetpack). We recommend using the AndroidX libraries in all new projects. You should also consider[migrating](https://developer.android.com/jetpack/androidx/migrate)existing projects to AndroidX. To find the AndroidX class that maps to this deprecated class, see the AndroidX support library[class mappings](https://developer.android.com/jetpack/androidx/migrate/class-mappings).

`
public
static


class
AccessibilityNodeInfoCompat.CollectionItemInfoCompat
`  
`

extends Object


``


`

|---|--------------------------------------------------------------------------------------------|
| java.lang.Object                                                                              ||
| ↳ | android.support.v4.view.accessibility.AccessibilityNodeInfoCompat.CollectionItemInfoCompat |

<br />

*** ** * ** ***

Class with information if a node is a collection item.

A collection item is contained in a collection, it starts at a given row and column in the collection, and spans one or more rows and columns. For example, a header of two related table columns starts at the first row and the first column, spans one row and two columns.

<br />

## Summary

|                                                                                                                                                                                                                                                                            ### Public methods                                                                                                                                                                                                                                                                            ||
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` int`                                                                                                                                                                                               | ` `[getColumnIndex](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#getColumnIndex())`() ` Gets the column index at which the item is located.                                                                                                                                  |
| ` int`                                                                                                                                                                                               | ` `[getColumnSpan](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#getColumnSpan())`() ` Gets the number of columns the item spans.                                                                                                                                             |
| ` int`                                                                                                                                                                                               | ` `[getRowIndex](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#getRowIndex())`() ` Gets the row index at which the item is located.                                                                                                                                           |
| ` int`                                                                                                                                                                                               | ` `[getRowSpan](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#getRowSpan())`() ` Gets the number of rows the item spans.                                                                                                                                                      |
| ` boolean`                                                                                                                                                                                           | ` `[isHeading](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#isHeading())`() ` Gets if the collection item is a heading.                                                                                                                                                      |
| ` boolean`                                                                                                                                                                                           | ` `[isSelected](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#isSelected())`() ` Gets if the collection item is selected.                                                                                                                                                     |
| ` static `[AccessibilityNodeInfoCompat.CollectionItemInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat) | ` `[obtain](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#obtain(int, int, int, int, boolean))`(int rowIndex, int rowSpan, int columnIndex, int columnSpan, boolean heading) ` Returns a cached instance if such is available otherwise a new one.                            |
| ` static `[AccessibilityNodeInfoCompat.CollectionItemInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat) | ` `[obtain](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#obtain(int, int, int, int, boolean, boolean))`(int rowIndex, int rowSpan, int columnIndex, int columnSpan, boolean heading, boolean selected) ` Returns a cached instance if such is available otherwise a new one. |

| ### Inherited methods |
|-----------------------|---|
| [![](https://developer.android.com/static/assets/images/styles/disclosure_down.png)](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat#)From class` java.lang.Object ` |-------------------|-------------------------------| | ` Object`         | ` clone() `                   | | ` boolean`        | ` equals(Object arg0) `       | | ` void`           | ` finalize() `                | | ` final Class<?>` | ` getClass() `                | | ` int`            | ` hashCode() `                | | ` final void`     | ` notify() `                  | | ` final void`     | ` notifyAll() `               | | ` String`         | ` toString() `                | | ` final void`     | ` wait(long arg0, int arg1) ` | | ` final void`     | ` wait(long arg0) `           | | ` final void`     | ` wait() `                    | ||

## Public methods

### getColumnIndex

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getColumnIndex ()
```

Gets the column index at which the item is located.

<br />

|             Returns             ||
|-------|--------------------------|
| `int` | The column index. <br /> |

### getColumnSpan

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getColumnSpan ()
```

Gets the number of columns the item spans.

<br />

|            Returns             ||
|-------|-------------------------|
| `int` | The column span. <br /> |

### getRowIndex

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getRowIndex ()
```

Gets the row index at which the item is located.

<br />

|           Returns            ||
|-------|-----------------------|
| `int` | The row index. <br /> |

### getRowSpan

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getRowSpan ()
```

Gets the number of rows the item spans.

<br />

|           Returns           ||
|-------|----------------------|
| `int` | The row span. <br /> |

### isHeading

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean isHeading ()
```

Gets if the collection item is a heading. For example, section heading, table header, etc.

<br />

|                   Returns                   ||
|-----------|----------------------------------|
| `boolean` | If the item is a heading. <br /> |

### isSelected

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean isSelected ()
```

Gets if the collection item is selected.

<br />

|                  Returns                   ||
|-----------|---------------------------------|
| `boolean` | If the item is selected. <br /> |

### obtain

added in[version 25.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
AccessibilityNodeInfoCompat.CollectionItemInfoCompat obtain (int rowIndex, 
                int rowSpan, 
                int columnIndex, 
                int columnSpan, 
                boolean heading)
```

Returns a cached instance if such is available otherwise a new one.

<br />

|                                 Parameters                                  ||
|---------------|--------------------------------------------------------------|
| `rowIndex`    | `int`: The row index at which the item is located. <br />    |
| `rowSpan`     | `int`: The number of rows the item spans. <br />             |
| `columnIndex` | `int`: The column index at which the item is located. <br /> |
| `columnSpan`  | `int`: The number of columns the item spans. <br />          |
| `heading`     | `boolean`: Whether the item is a heading. <br />             |

|                                                                                                     Returns                                                                                                     ||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------|
| [AccessibilityNodeInfoCompat.CollectionItemInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat) | An instance. <br /> |

### obtain

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
AccessibilityNodeInfoCompat.CollectionItemInfoCompat obtain (int rowIndex, 
                int rowSpan, 
                int columnIndex, 
                int columnSpan, 
                boolean heading, 
                boolean selected)
```

Returns a cached instance if such is available otherwise a new one.

<br />

|                                 Parameters                                  ||
|---------------|--------------------------------------------------------------|
| `rowIndex`    | `int`: The row index at which the item is located. <br />    |
| `rowSpan`     | `int`: The number of rows the item spans. <br />             |
| `columnIndex` | `int`: The column index at which the item is located. <br /> |
| `columnSpan`  | `int`: The number of columns the item spans. <br />          |
| `heading`     | `boolean`: Whether the item is a heading. <br />             |
| `selected`    | `boolean`: Whether the item is selected. <br />              |

|                                                                                                     Returns                                                                                                     ||
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------|
| [AccessibilityNodeInfoCompat.CollectionItemInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat) | An instance. <br /> |

-

  ## Interfaces

  - [AccessibilityManagerCompat.AccessibilityStateChangeListener](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityManagerCompat.AccessibilityStateChangeListener)
  - [AccessibilityManagerCompat.TouchExplorationStateChangeListener](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityManagerCompat.TouchExplorationStateChangeListener)
-

  ## Classes

  - [AccessibilityEventCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityEventCompat)
  - [AccessibilityManagerCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityManagerCompat)
  - [AccessibilityManagerCompat.AccessibilityStateChangeListenerCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityManagerCompat.AccessibilityStateChangeListenerCompat)
  - [AccessibilityNodeInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat)
  - [AccessibilityNodeInfoCompat.AccessibilityActionCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.AccessibilityActionCompat)
  - [AccessibilityNodeInfoCompat.CollectionInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionInfoCompat)
  - [AccessibilityNodeInfoCompat.CollectionItemInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.CollectionItemInfoCompat)
  - [AccessibilityNodeInfoCompat.RangeInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeInfoCompat.RangeInfoCompat)
  - [AccessibilityNodeProviderCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityNodeProviderCompat)
  - [AccessibilityRecordCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityRecordCompat)
  - [AccessibilityWindowInfoCompat](https://developer.android.com/reference/android/support/v4/view/accessibility/AccessibilityWindowInfoCompat)