Instance Method

index(ofAccessibilityElement:)

Returns the index of the specified accessibility element.

Declaration

func index(ofAccessibilityElement element: Any) -> Int

Parameters

element

The accessibility element.

Return Value

The index of the specified accessibility element, or NSNotFound if the element does not exist.

See Also

Providing Information About Accessibility Elements

func accessibilityElementCount() -> Int

Returns the number of accessibility elements in the container.

func accessibilityElement(at: Int) -> Any?

Returns the accessibility element at the specified index.

var accessibilityElements: [Any]?

An array of the accessibility elements in the container.

var accessibilityContainerType: UIAccessibilityContainerType

The type of container used for accessibility elements, such as tables or lists.

enum UIAccessibilityContainerType

Constants indicating the type of content stored in a data-based container.