Class HiddenHtmlElementState
- java.lang.Object
-
- com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState
-
- All Implemented Interfaces:
IHtmlElementState
public class HiddenHtmlElementState extends Object implements IHtmlElementState
Check the state of an HTML element
-
-
Constructor Summary
Constructors Constructor Description HiddenHtmlElementState(UiElement uiElement)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidfocus()Moves the focus to the specified element.voidhighlightElement()Tries to briefly change the element's background color to yellow.booleanisElementDisplayed()Check whether the element is displayed or notbooleanisElementEnabled()booleanisElementPresent()voidverifyExist()Verifies the element exist throws an exception if verification failvoidverifyNotExist()Verifies the element does NOT exist throws an exception if verification failvoidwaitToBecomeDisabled()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become disabled throws an exception if it does not become disabled for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeDisabled(int millis)Waits for a period of time the element to become disabled throws an exception if it does not become disabled for the specified periodvoidwaitToBecomeDisplayed()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become displayed throws an exception if it does not become displayed for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeDisplayed(int millis)Waits for a period of time the element to become displayed throws an exception if it does not become displayed for the specified periodvoidwaitToBecomeEnabled()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become enabled throws an exception if it does not become enabled for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeEnabled(int millis)Waits for a period of time the element to become enabled throws an exception if it does not become enabled for the specified periodvoidwaitToBecomeExisting()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become existing throws an exception if it does not become existing for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeExisting(int millis)Waits for a period of time the element to become existing throws an exception if it does not become existing for the specified periodvoidwaitToBecomeHidden()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become hidden throws an exception if it does not become hidden for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeHidden(int millis)Waits for a period of time the element to become hidden throws an exception if it does not become hidden for the specified periodvoidwaitToBecomeNotExisting()Waits for a period of time (check the 'elementStateChangeDelay' property) the element to became non-existing throws an exception if it does not become non-existing for the default waiting period (check the 'elementStateChangeDelay' property)voidwaitToBecomeNotExisting(int millis)Waits for a period of time the element to became non-existing throws an exception if it does not become non-existing for the specified period
-
-
-
Constructor Detail
-
HiddenHtmlElementState
public HiddenHtmlElementState(UiElement uiElement)
- Parameters:
uiElement- the element of interest
-
-
Method Detail
-
verifyExist
public void verifyExist()
Verifies the element exist throws an exception if verification fail- Specified by:
verifyExistin interfaceIHtmlElementState
-
verifyNotExist
public void verifyNotExist()
Verifies the element does NOT exist throws an exception if verification fail- Specified by:
verifyNotExistin interfaceIHtmlElementState
-
waitToBecomeExisting
public void waitToBecomeExisting()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become existing throws an exception if it does not become existing for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeExistingin interfaceIHtmlElementState
-
waitToBecomeExisting
public void waitToBecomeExisting(int millis)
Waits for a period of time the element to become existing throws an exception if it does not become existing for the specified period- Specified by:
waitToBecomeExistingin interfaceIHtmlElementState
-
waitToBecomeNotExisting
public void waitToBecomeNotExisting()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to became non-existing throws an exception if it does not become non-existing for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeNotExistingin interfaceIHtmlElementState
-
waitToBecomeNotExisting
public void waitToBecomeNotExisting(int millis)
Waits for a period of time the element to became non-existing throws an exception if it does not become non-existing for the specified period- Specified by:
waitToBecomeNotExistingin interfaceIHtmlElementState
-
waitToBecomeDisplayed
public void waitToBecomeDisplayed()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become displayed throws an exception if it does not become displayed for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeDisplayedin interfaceIHtmlElementState
-
waitToBecomeDisplayed
public void waitToBecomeDisplayed(int millis)
Waits for a period of time the element to become displayed throws an exception if it does not become displayed for the specified period- Specified by:
waitToBecomeDisplayedin interfaceIHtmlElementState
-
waitToBecomeHidden
public void waitToBecomeHidden()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become hidden throws an exception if it does not become hidden for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeHiddenin interfaceIHtmlElementState
-
waitToBecomeHidden
public void waitToBecomeHidden(int millis)
Waits for a period of time the element to become hidden throws an exception if it does not become hidden for the specified period- Specified by:
waitToBecomeHiddenin interfaceIHtmlElementState
-
waitToBecomeEnabled
public void waitToBecomeEnabled()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become enabled throws an exception if it does not become enabled for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeEnabledin interfaceIHtmlElementState
-
waitToBecomeEnabled
public void waitToBecomeEnabled(int millis)
Waits for a period of time the element to become enabled throws an exception if it does not become enabled for the specified period- Specified by:
waitToBecomeEnabledin interfaceIHtmlElementState
-
waitToBecomeDisabled
public void waitToBecomeDisabled()
Waits for a period of time (check the 'elementStateChangeDelay' property) the element to become disabled throws an exception if it does not become disabled for the default waiting period (check the 'elementStateChangeDelay' property)- Specified by:
waitToBecomeDisabledin interfaceIHtmlElementState
-
waitToBecomeDisabled
public void waitToBecomeDisabled(int millis)
Waits for a period of time the element to become disabled throws an exception if it does not become disabled for the specified period- Specified by:
waitToBecomeDisabledin interfaceIHtmlElementState
-
isElementPresent
public boolean isElementPresent()
- Specified by:
isElementPresentin interfaceIHtmlElementState- Returns:
trueif the element exists
-
isElementEnabled
public boolean isElementEnabled()
- Specified by:
isElementEnabledin interfaceIHtmlElementState- Returns:
trueif the element is enabled
-
isElementDisplayed
public boolean isElementDisplayed()
Check whether the element is displayed or not- Specified by:
isElementDisplayedin interfaceIHtmlElementState- Returns:
trueif the element is displayed
-
focus
public void focus()
Description copied from interface:IHtmlElementStateMoves the focus to the specified element. Note: This is somewhat breakable as the browser window needs to be the active system window, otherwise the keyboard events will go to another application.- Specified by:
focusin interfaceIHtmlElementState
-
highlightElement
public void highlightElement()
Description copied from interface:IHtmlElementStateTries to briefly change the element's background color to yellow. Does not work on all elements. It is useful for debugging purposes.- Specified by:
highlightElementin interfaceIHtmlElementState
-
-