Package com.axway.ats.uiengine.engine
Class MobileEngine
- java.lang.Object
-
- com.axway.ats.uiengine.internal.engine.AbstractEngine
-
- com.axway.ats.uiengine.engine.MobileEngine
-
public class MobileEngine extends AbstractEngine
Engine operating with mobile application/device
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classMobileEngine.Device
-
Field Summary
-
Fields inherited from class com.axway.ats.uiengine.internal.engine.AbstractEngine
elementsFactory, uiDriver
-
-
Constructor Summary
Constructors Constructor Description MobileEngine(UiDriver uiDriver, AbstractElementsFactory elementsFactory)MobileEngine(UiDriver uiDriver, MobileDeviceUtils mobileDeviceUtils)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecuteScript(String method, Object... args)StringexecuteScriptAndReturn(String method, Object... args)StringgetApplicationName()Get current application as StringString[]getAvailableContexts()MobileButtongetButton(UiElementProperties properties)Get access to button element (native/or HTML one)MobileButtongetButton(String mapId)Get access to button element (native/or HTML one)MobileCheckBoxgetCheckBox(UiElementProperties properties)Get access to check box element (native/or HTML one)MobileCheckBoxgetCheckBox(String mapId)Get access to check box element (native/or HTML one)StringgetContext()MobileEngine.DevicegetDevice()MobileElement<?>getElement(UiElementProperties properties)Get access to generic UI element (could be used for div/span or other UI type element)MobileElement<?>getElement(String mapId)Get access to generic UI element (could be used for div/span or other UI type element)MobileLabelgetLabel(UiElementProperties properties)Get access to text box element (native/or HTML one where text edit is not accepted)MobileLabelgetLabel(String mapId)Get access to text label element (native/or HTML one where text edit is not accepted)MobileLinkgetLink(UiElementProperties properties)Get access to link elementMobileLinkgetLink(String mapId)Get access to link( href) elementStringgetPageSource()Get page source as StringMobileTextBoxgetTextBox(UiElementProperties properties)Get access to text box element (native/or HTML one where text edit is accepted)MobileTextBoxgetTextBox(String mapId)Get access to text box element (native/or HTML one where text edit is accepted)MobileElementStategetUtilsElementState(UiElement uiElement)Check element statevoidsetContext(String context)-
Methods inherited from class com.axway.ats.uiengine.internal.engine.AbstractEngine
getMapSection, loadMapFile, setMapSection
-
-
-
-
Constructor Detail
-
MobileEngine
public MobileEngine(UiDriver uiDriver, MobileDeviceUtils mobileDeviceUtils)
-
MobileEngine
public MobileEngine(UiDriver uiDriver, AbstractElementsFactory elementsFactory)
-
-
Method Detail
-
getApplicationName
public String getApplicationName()
Get current application as String
-
getButton
public MobileButton getButton(String mapId)
Get access to button element (native/or HTML one)- Parameters:
mapId- the element's map id- Returns:
- a new
MobileButtoninstance
-
getButton
public MobileButton getButton(UiElementProperties properties)
Get access to button element (native/or HTML one)- Parameters:
properties- properties describing this element- Returns:
- a new
MobileButtoninstance
-
getTextBox
public MobileTextBox getTextBox(String mapId)
Get access to text box element (native/or HTML one where text edit is accepted)- Parameters:
mapId- the element's map id- Returns:
- a new
MobileTextBoxinstance
-
getTextBox
public MobileTextBox getTextBox(UiElementProperties properties)
Get access to text box element (native/or HTML one where text edit is accepted)- Parameters:
properties- properties describing this element- Returns:
- a new
MobileTextBoxinstance
-
getLabel
public MobileLabel getLabel(String mapId)
Get access to text label element (native/or HTML one where text edit is not accepted)- Parameters:
mapId- the element's map id- Returns:
- a new
MobileLabelinstance
-
getLabel
public MobileLabel getLabel(UiElementProperties properties)
Get access to text box element (native/or HTML one where text edit is not accepted)- Parameters:
properties- properties describing this element- Returns:
- a new
MobileLabelinstance
-
getCheckBox
public MobileCheckBox getCheckBox(String mapId)
Get access to check box element (native/or HTML one)- Parameters:
mapId- the element's map id- Returns:
- a new
MobileCheckBoxinstance
-
getCheckBox
public MobileCheckBox getCheckBox(UiElementProperties properties)
Get access to check box element (native/or HTML one)- Parameters:
properties- properties describing this element- Returns:
- a new
MobileCheckBoxinstance
-
getLink
public MobileLink getLink(String mapId)
Get access to link( href) element- Parameters:
mapId- the element's map id- Returns:
- a new
MobileLinkinstance
-
getLink
public MobileLink getLink(UiElementProperties properties)
Get access to link element- Parameters:
properties- properties describing this element- Returns:
- a new
MobileLinkinstance
-
getElement
public MobileElement<?> getElement(String mapId)
Get access to generic UI element (could be used for div/span or other UI type element)- Parameters:
mapId- the element's map id- Returns:
- a new
MobileElementinstance
-
getElement
public MobileElement<?> getElement(UiElementProperties properties)
Get access to generic UI element (could be used for div/span or other UI type element)- Parameters:
properties- properties describing this element- Returns:
- a new
MobileElementinstance
-
getUtilsElementState
public MobileElementState getUtilsElementState(UiElement uiElement)
Check element state- Parameters:
uiElement- the element to work with- Returns:
- a utility class for checking the state of element
-
getPageSource
public String getPageSource()
Get page source as String- Returns:
- page source
-
getContext
public String getContext()
-
setContext
public void setContext(String context)
-
getAvailableContexts
public String[] getAvailableContexts()
-
getDevice
public MobileEngine.Device getDevice()
-
-