Class Switch
- java.lang.Object
-
- net.serenitybdd.screenplay.actions.Switch
-
public class Switch extends Object
Switch to a different frame or window. This wraps the WebDriver.switchTo() methods as Screenplay interactions.
-
-
Constructor Summary
Constructors Constructor Description Switch()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static PerformabletoActiveElement()static PerformabletoAlert()static PerformabletoDefaultContext()static PerformabletoFrame(Integer frameId)static PerformabletoFrame(String frameName)static PerformabletoFrame(org.openqa.selenium.WebElement webElement)static PerformabletoNewWindow()static PerformabletoParentFrame()static PerformabletoTheOtherWindow()Switch to the first window that is not the current window.static PerformabletoWindow(String nameOrHandle)static PerformabletoWindowTitled(String title)
-
-
-
Method Detail
-
toFrame
public static Performable toFrame(Integer frameId)
-
toFrame
public static Performable toFrame(String frameName)
-
toFrame
public static Performable toFrame(org.openqa.selenium.WebElement webElement)
-
toParentFrame
public static Performable toParentFrame()
-
toWindow
public static Performable toWindow(String nameOrHandle)
-
toNewWindow
public static Performable toNewWindow()
-
toWindowTitled
public static Performable toWindowTitled(String title)
-
toTheOtherWindow
public static Performable toTheOtherWindow()
Switch to the first window that is not the current window.- Returns:
-
toAlert
public static Performable toAlert()
-
toDefaultContext
public static Performable toDefaultContext()
-
toActiveElement
public static Performable toActiveElement()
-
-