pub struct SwitchTo { /* private fields */ }
Expand description
Struct for switching between frames/windows/alerts.
Implementations§
Source§impl SwitchTo
impl SwitchTo
Sourcepub fn new(handle: SessionHandle) -> Self
pub fn new(handle: SessionHandle) -> Self
Create a new SwitchTo struct. This is typically created internally
via a call to WebDriver::switch_to()
.
pub async fn active_element(self) -> WebDriverResult<WebElement>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::active_element()
pub fn alert(self) -> Alert
👎Deprecated since 0.30.0: This method has been deprecated. See the
Alert
module for new method namespub async fn default_content(self) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::enter_default_frame()
pub async fn frame_number(self, frame_number: u16) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::enter_frame()
pub async fn frame_element( self, frame_element: &WebElement, ) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebElement::enter_frame()
pub async fn parent_frame(self) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::enter_parent_frame()
pub async fn new_window(self) -> WebDriverResult<WindowHandle>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::new_window()
pub async fn new_tab(self) -> WebDriverResult<WindowHandle>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::new_tab()
pub async fn window(self, handle: WindowHandle) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::switch_to_window()
pub async fn window_name(self, name: &str) -> WebDriverResult<()>
👎Deprecated since 0.30.0: This method has been moved to WebDriver::switch_to_named_window()
Auto Trait Implementations§
impl Freeze for SwitchTo
impl !RefUnwindSafe for SwitchTo
impl Send for SwitchTo
impl Sync for SwitchTo
impl Unpin for SwitchTo
impl !UnwindSafe for SwitchTo
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