public class Frame
extends java.lang.Object
Browser.frame()
.
This class is used to switch the focus between different frames and iframes.
Constructor and Description |
---|
Frame(Browser browser)
Constructs new BrowserFrame instance to interact with browser frames
|
Modifier and Type | Method and Description |
---|---|
void |
switchTo(HtmlElement frame)
Switches to frame which is specified by given
HtmlElement . |
void |
switchTo(java.lang.String name)
Switches to frame with specified name.
|
void |
switchToMain()
Switches to main content in this window.
|
public Frame(Browser browser)
browser
- Browser
instance to work withpublic void switchToMain()
public void switchTo(java.lang.String name)
name
- public void switchTo(HtmlElement frame)
HtmlElement
.frame
- frame or iframe HtmlElement