Package io.appium.java_client.remote
Interface SupportsContextSwitching
-
- All Superinterfaces:
org.openqa.selenium.ContextAware
,ExecutesMethod
,org.openqa.selenium.SearchContext
,org.openqa.selenium.WebDriver
- All Known Implementing Classes:
AndroidDriver
,FlutterAndroidDriver
,FlutterIOSDriver
,IOSDriver
public interface SupportsContextSwitching extends org.openqa.selenium.WebDriver, org.openqa.selenium.ContextAware, ExecutesMethod
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default org.openqa.selenium.WebDriver
context(java.lang.String name)
Switches to the given context.default java.lang.String
getContext()
Get the name of the current context.default java.util.Set<java.lang.String>
getContextHandles()
Get the names of available contexts.-
Methods inherited from interface io.appium.java_client.ExecutesMethod
execute, execute
-
-
-
-
Method Detail
-
context
default org.openqa.selenium.WebDriver context(java.lang.String name)
Switches to the given context.- Specified by:
context
in interfaceorg.openqa.selenium.ContextAware
- Parameters:
name
- The name of the context to switch to.- Returns:
- self instance for chaining.
-
getContextHandles
default java.util.Set<java.lang.String> getContextHandles()
Get the names of available contexts.- Specified by:
getContextHandles
in interfaceorg.openqa.selenium.ContextAware
- Returns:
- List list of context names.
-
getContext
@Nullable default java.lang.String getContext()
Get the name of the current context.- Specified by:
getContext
in interfaceorg.openqa.selenium.ContextAware
- Returns:
- Context name or null if it cannot be determined.
-
-