|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.team.fvt.tests.web.WebPageElement
com.ibm.team.fvt.tests.web.WebElementWrapper
com.ibm.team.fvt.tests.web.WebExpandableElement
public class WebExpandableElement
Default class to handle expandable web element in a web page.
By default the expansion mechanism of the web element is managed by its
aria-expanded
attribute. If the wrapped web element does
not have this attribute, then a ScenarioFailedError
is raised when any
expand or collapse action is requested.
This class might be subclasses to override this default mechanism.
Constructor Summary | |
---|---|
WebExpandableElement(WebPage page,
org.openqa.selenium.By findBy)
|
|
WebExpandableElement(WebPage page,
org.openqa.selenium.By findBy,
org.openqa.selenium.By expansionBy)
|
|
WebExpandableElement(WebPage page,
WebBrowserElement node)
|
|
WebExpandableElement(WebPage page,
WebBrowserElement node,
org.openqa.selenium.By expansionBy)
|
Method Summary | |
---|---|
void |
collapse()
Expand the current web element. |
void |
expand()
Expand the current web element. |
boolean |
isExpandable()
Returns whether the current wrapped web element is expandable or not. |
boolean |
isExpanded()
Returns whether the current wrapped web element is expanded or not. |
void |
toggle()
Expand the current web element. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public WebExpandableElement(WebPage page, org.openqa.selenium.By findBy)
public WebExpandableElement(WebPage page, org.openqa.selenium.By findBy, org.openqa.selenium.By expansionBy)
public WebExpandableElement(WebPage page, WebBrowserElement node)
public WebExpandableElement(WebPage page, WebBrowserElement node, org.openqa.selenium.By expansionBy)
Method Detail |
---|
public void collapse() throws ScenarioFailedError
If the web element is already expanded, then nothing happens.
ScenarioFailedError
- If the wrapped web element does not have
the aria-expanded
attribute.public void expand() throws ScenarioFailedError
If the web element is already expanded, then nothing happens.
ScenarioFailedError
- If the wrapped web element does not have
the aria-expanded
attribute.public boolean isExpandable() throws ScenarioFailedError
true
if the current node is expanda, false>/code>
otherwise.
- Throws:
ScenarioFailedError
- If the wrapped web element does not have
the aria-expanded
attribute.
public boolean isExpanded() throws ScenarioFailedError
true
if the current node is expanded, false>/code>
otherwise.
- Throws:
ScenarioFailedError
- If the wrapped web element does not have
the aria-expanded
attribute.
public final void toggle() throws ScenarioFailedError
If the web element is already expanded, then nothing happens.
ScenarioFailedError
- If the wrapped web element does not have
the aria-expanded
attribute.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |