java_get_element
Inspect a single Java UI element by handle and verify it still matches its recorded role, name, position, and bounds, reporting any differences.
Instructions
Everything known about one element, and whether it is still the same element.
Use this after java_snapshot or java_find to look at one control in detail, or to confirm that a handle still points at what it did. The handle is resolved again and compared against what was recorded when it was handed out; if anything differs -- role, name, position among siblings, bounds -- this reports the difference instead of presenting the element as if nothing had changed.
Args:
session_id: From java_attach_window.
handle: An e:... handle from a snapshot or a find.
Returns: The element's role, name, description, states, bounds, index and depth, its locator, and the verification result.
Errors:
is_error for an unknown handle (the message says to take a fresh snapshot),
for a handle belonging to another session, or when the element has changed.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"session_id": "<session_id>",
"handle": "<handle>"
},
"name": "java_get_element"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| handle | Yes | ||
| session_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |