Package io.flutter.embedding.engine

# Interface FlutterJNI.AccessibilityDelegate

All Known Subinterfaces:
  `AccessibilityChannel.AccessibilityMessageHandler`

Enclosing class:
  `FlutterJNI`

public static interface FlutterJNI.AccessibilityDelegate
Delegate responsible for creating and updating Android-side caches of Flutter's semantics tree and custom accessibility actions.

`AccessibilityBridge` is an example of an `AccessibilityDelegate`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `resetSemantics()`
  Invoked by native to notify embedder to reset accessibility tree.
  `void`
  `setLocale(String locale)`
  Sets the locale for the assistive technologies.
  `void`
  `updateCustomAccessibilityActions(ByteBuffer buffer, String[] strings)`
  Sends new custom accessibility actions from Flutter to Android.
  `void`
  `updateSemantics(ByteBuffer buffer, String[] strings, ByteBuffer[] stringAttributeArgs)`
  Sends new `SemanticsNode` information from Flutter to Android.

- ## Method Details

  - ### updateCustomAccessibilityActions

    void updateCustomAccessibilityActions(@NonNull ByteBuffer buffer, @NonNull String[] strings)
    Sends new custom accessibility actions from Flutter to Android.

    Implementers are expected to maintain an Android-side cache of custom accessibility actions. This method provides new actions to add to that cache.

  - ### updateSemantics

    void updateSemantics(@NonNull ByteBuffer buffer, @NonNull String[] strings, @NonNull ByteBuffer[] stringAttributeArgs)
    Sends new `SemanticsNode` information from Flutter to Android.

    Implementers are expected to maintain an Android-side cache of Flutter's semantics tree. This method provides updates from Flutter for the Android-side semantics tree cache.

  - ### setLocale

    void setLocale(@NonNull String locale)
    Sets the locale for the assistive technologies.

    Must be called on the main thread

  - ### resetSemantics

    void resetSemantics()
    Invoked by native to notify embedder to reset accessibility tree.

    The embedding needs to be prepare to clean up previously stored caches.