pub struct Accessibility { /* private fields */ }Expand description
Provides accessibility-tree inspection methods on a page.
Access via Page::accessibility.
Implementations§
Source§impl Accessibility
impl Accessibility
Sourcepub async fn snapshot(
&self,
options: impl Into<Option<AccessibilitySnapshotOptions>>,
) -> Result<Value>
pub async fn snapshot( &self, options: impl Into<Option<AccessibilitySnapshotOptions>>, ) -> Result<Value>
Captures the current state of the page’s accessibility tree.
Returns the accessibility tree as a JSON Value (tree of nodes with
role, name, value, children, etc.), or null when there is no
accessibility tree.
§Errors
Returns error if the RPC call fails or the browser has been closed.
See: https://playwright.dev/docs/api/class-accessibility#accessibility-snapshot
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Accessibility
impl !RefUnwindSafe for Accessibility
impl !UnwindSafe for Accessibility
impl Send for Accessibility
impl Sync for Accessibility
impl Unpin for Accessibility
impl UnsafeUnpin for Accessibility
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more