added in version 22.1.0
belongs to Maven artifact com.android.support:recyclerview-v7:28.0.0-alpha1

RecyclerViewAccessibilityDelegate

public class RecyclerViewAccessibilityDelegate
extends AccessibilityDelegateCompat

java.lang.Object
   ↳ android.support.v4.view.AccessibilityDelegateCompat
     ↳ android.support.v7.widget.RecyclerViewAccessibilityDelegate


The AccessibilityDelegate used by RecyclerView.

This class handles basic accessibility actions and delegates them to LayoutManager.

Summary

Nested classes

class RecyclerViewAccessibilityDelegate.ItemDelegate

The default implementation of accessibility delegate for the individual items of the RecyclerView. 

Public constructors

RecyclerViewAccessibilityDelegate(RecyclerView recyclerView)

Public methods

AccessibilityDelegateCompat getItemDelegate()

Gets the AccessibilityDelegate for an individual item in the RecyclerView.

void onInitializeAccessibilityEvent(View host, AccessibilityEvent event)

Initializes an AccessibilityEvent with information about the the host View which is the event source.

void onInitializeAccessibilityNodeInfo(View host, AccessibilityNodeInfoCompat info)

Initializes an AccessibilityNodeInfoCompat with information about the host view.

boolean performAccessibilityAction(View host, int action, Bundle args)

Performs the specified accessibility action on the view.

Inherited methods

From class android.support.v4.view.AccessibilityDelegateCompat
From class java.lang.Object

Public constructors

RecyclerViewAccessibilityDelegate

added in version 22.1.0
RecyclerViewAccessibilityDelegate (RecyclerView recyclerView)

Parameters
recyclerView RecyclerView

Public methods

getItemDelegate

added in version 24.1.0
AccessibilityDelegateCompat getItemDelegate ()

Gets the AccessibilityDelegate for an individual item in the RecyclerView. A basic item delegate is provided by default, but you can override this method to provide a custom per-item delegate.

Returns
AccessibilityDelegateCompat

onInitializeAccessibilityEvent

added in version 22.1.0
void onInitializeAccessibilityEvent (View host, 
                AccessibilityEvent event)

Initializes an AccessibilityEvent with information about the the host View which is the event source.

The default implementation behaves as ViewCompat#onInitalizeAccessibilityEvent(View v, AccessibilityEvent event) for the case of no accessibility delegate been set.

Parameters
host View: The View hosting the delegate.

event AccessibilityEvent: The event to initialize.

onInitializeAccessibilityNodeInfo

added in version 22.1.0
void onInitializeAccessibilityNodeInfo (View host, 
                AccessibilityNodeInfoCompat info)

Initializes an AccessibilityNodeInfoCompat with information about the host view.

The default implementation behaves as ViewCompat#onInitializeAccessibilityNodeInfo(View, AccessibilityNodeInfoCompat) for the case of no accessibility delegate been set.

Parameters
host View: The View hosting the delegate.

info AccessibilityNodeInfoCompat: The instance to initialize.

performAccessibilityAction

added in version 22.1.0
boolean performAccessibilityAction (View host, 
                int action, 
                Bundle args)

Performs the specified accessibility action on the view. For possible accessibility actions look at AccessibilityNodeInfoCompat.

The default implementation behaves as View#performAccessibilityAction(int, Bundle) for the case of no accessibility delegate been set.

Parameters
host View

action int: The action to perform.

args Bundle

Returns
boolean Whether the action was performed.