Cursor
yosoi.surface.Cursor
class Cursor:
Owned navigation cursor. Close it to release watches and hot authority.
Source: python/yosoi/surface.py:1425
Members below are declared on this class. Inherited Pydantic methods and generated constructor signatures are not expanded.
Methods
Section titled “Methods”def __init__(self, handle: _native.SurfaceCursor) -> None:
Wrap a cursor allocated by Session.cursor.
Source: python/yosoi/surface.py:1428
def __enter__(self) -> Self:
Use a cursor with deterministic cleanup.
Source: python/yosoi/surface.py:1432
def __exit__(self, *_: object) -> None:
Release this cursor even when the body raises.
Source: python/yosoi/surface.py:1436
@property
def id(self) -> int:
Return a session-local diagnostic identity, without authority.
Source: python/yosoi/surface.py:1446
status
Section titled “status”@property
def status(self) -> CursorState:
Inspect attachment, authority, subscriptions and evidence freshness.
Source: python/yosoi/surface.py:1451
position
Section titled “position”@property
def position(self) -> Position:
Return the saved region, focus and continuation.
Source: python/yosoi/surface.py:1456
overview
Section titled “overview”def overview(self, *, continuation: Continuation | None=None, budget: Budget | None=None) -> NativePage:
Read current evidence and save its navigation continuation.
Source: python/yosoi/surface.py:1476
def find(self, query: str, *, continuation: Continuation | None=None, budget: Budget | None=None) -> NativePage:
Search current captured evidence without promoting the cursor.
Source: python/yosoi/surface.py:1484
expand
Section titled “expand”def expand(self, reference: NativeReference, *, continuation: Continuation | None=None, budget: Budget | None=None) -> NativePage:
Drill into evidence and save scope without granting action authority.
Source: python/yosoi/surface.py:1496
inspect
Section titled “inspect”def inspect(self, reference: NativeReference, *, continuation: Continuation | None=None, budget: Budget | None=None) -> NativeInspection:
Read exact captured detail and save focus, preserving its freshness.
Source: python/yosoi/surface.py:1508
def focus(self, reference: NativeReference) -> None:
Select exact evidence; this does not prove current UI eligibility.
Source: python/yosoi/surface.py:1520
subscribe
Section titled “subscribe”def subscribe(self, reference: NativeReference) -> int:
Watch a captured block; an adapter must publish and reconcile updates.
Source: python/yosoi/surface.py:1524
reconcile
Section titled “reconcile”def reconcile(self, watch: int, replacement: NativeReference) -> EventKind:
Compare replacement evidence without asserting durable entity identity.
Source: python/yosoi/surface.py:1528
unsubscribe
Section titled “unsubscribe”def unsubscribe(self, watch: int) -> None:
Remove this cursor’s subscription without moving its focus.
Source: python/yosoi/surface.py:1534
events
Section titled “events”def events(self) -> EventBatch:
Consume retained events; lost is true when unread history was evicted.
Source: python/yosoi/surface.py:1538
promote
Section titled “promote”def promote(self) -> None:
Acquire the single hot slot; detached or competing owners are rejected.
Source: python/yosoi/surface.py:1542
def cool(self) -> None:
Release hot authority; an in-flight action prevents unsafe handoff.
Source: python/yosoi/surface.py:1546
begin_action
Section titled “begin_action”def begin_action(self) -> ActionLease:
Lease focus; the adapter still checks visibility and eligibility.
Source: python/yosoi/surface.py:1550
def close(self) -> None:
Release owned cursor state; further cursor operations are rejected.