public class Switch extends Object
Constructor and Description |
---|
Switch() |
Modifier and Type | Method and Description |
---|---|
static Performable |
toActiveElement()
Switches to the element that currently has focus within the document currently "switched to", or the body element if this cannot be detected.
|
static AlertAction |
toAlert()
Switch focus to an HTML alert window
|
static Performable |
toDefaultContext()
Selects either the first frame on the page, or the main document when a page contains iframes.
|
static Performable |
toFrame(Integer frameId) |
static Performable |
toFrame(String frameName) |
static Performable |
toFrame(org.openqa.selenium.WebElement webElement) |
static Performable |
toNewWindow() |
static Performable |
toNewWindow(org.openqa.selenium.WindowType windowType)
Switch to a window of a specified type (WINDOW or TAB)
|
static Performable |
toParentFrame() |
static Performable |
toTheOtherWindow()
Switch to the first window that is not the current window.
|
static Performable |
toWindow(String nameOrHandle) |
static Performable |
toWindowTitled(String title) |
public static Performable toFrame(Integer frameId)
public static Performable toNewWindow(org.openqa.selenium.WindowType windowType)
public static Performable toFrame(String frameName)
public static Performable toFrame(org.openqa.selenium.WebElement webElement)
public static Performable toParentFrame()
public static Performable toWindow(String nameOrHandle)
public static Performable toNewWindow()
public static Performable toWindowTitled(String title)
public static Performable toTheOtherWindow()
public static AlertAction toAlert()
public static Performable toDefaultContext()
public static Performable toActiveElement()
Copyright © 2023. All rights reserved.