Skip to main content

AccessibilityFocusedElement

Description

Use this command to get the currently highlighted element by Accessibility Inspector. 

Parameters

None.

Return Value

JSON representing element properties. Example return value:

{"ElementHash":"WAMAAABy7oICAAAAEQAAAAAAAAA","Value":"0","Class":"UIAccessibilityPickerComponent","Traits":"Adjustable"}

Usage

info

Replace <server> with the appropriate URL.

Java

DesiredCapabilities dc = new DesiredCapabilities();
dc.setCapability(MobileCapabilityType.UDID, "<deviceid>");
driver = new AndroidDriver(new URL("<server>"), dc);
SeeTestClient seetest = new SeeTestClient(driver);

...
...

String str = seetest.accessibilityFocusedElement();