Package core.helpers.click
Class ClickHelperAction
java.lang.Object
core.helpers.Element
core.helpers.click.ClickHelperAction
public class ClickHelperAction extends Element
-
Nested Class Summary
Nested classes/interfaces inherited from class core.helpers.Element
Element.LocatorType -
Constructor Summary
Constructors Constructor Description ClickHelperAction() -
Method Summary
Modifier and Type Method Description voidclickAction(EnhancedBy target, int index)click using actionsvoidclickAndExpect(EnhancedBy target, int index, EnhancedBy expected)clicks element based on index And waits for expected element to be displayedvoidclickAndExpect(EnhancedBy target, int index, EnhancedBy expected, boolean mobileRefresh)clicks element based on index And waits for expected element to be displayedvoidclickAndExpect(EnhancedBy target, int index, EnhancedBy expected1, EnhancedBy expected2)click And expect for either elementvoidclickAndExpect(EnhancedBy target, EnhancedBy expected)clicks target And waits for expected element to display retries 10 timesvoidclickAndExpect(EnhancedBy target, EnhancedBy expected, boolean mobileRefresh)voidclickAndExpect(EnhancedBy target, EnhancedBy expected, EnhancedBy spinner)clicks target And waits for expected element to show up also waits for spinner element to be removed from displayvoidclickAndExpectByText(EnhancedBy target, String text, EnhancedBy expected)click And expect based on the text value on the element.voidclickAndHold(EnhancedBy target, double seconds)click And hold elementvoidclickAndHold(EnhancedBy target, int index, double seconds)click And hold based on element indexvoidclickAndNotExpect(EnhancedBy target, int index, EnhancedBy expected)clicks target And waits for expected to not be displayed retries 10 timesvoidclickAndNotExpect(EnhancedBy target, EnhancedBy expected)voidclickAndWait(EnhancedBy target, double timeInSeconds)clicks target And waits for secondsvoidclickAndWait(EnhancedBy target, int index, double timeInSeconds)clicks target And waits for secondsvoidclickElementContinsByText(EnhancedBy by, String text)click element with text containingvoidclickElementLocationBy(EnhancedBy by, int x, int y)Click on an element's specific x,y locationvoidclickPoints(int x, int y)click at position x, yvoiddoubleClick(EnhancedBy target, int index)double click on elementvoiddoubleClickPoints(int x, int y)double click at positionvoiddragAndDrop(EnhancedBy src, int xOffset, int yOffset)drag And drop from src element to target elementvoiddragAndDrop(EnhancedBy src, EnhancedBy target)drag And drop from src element to target elementvoidrightClick(int x, int y)right click on x, y pointsvoidrightClick(EnhancedBy target, int index)right click on element at indexMethods inherited from class core.helpers.Element
byAccessibility, byClass, byCss, byId, byLinkText, byName, byPartialLinkText, byTagName, byTextXpath, byXpath, byXpathContentDesc, findElements, findElements, findElements
-
Constructor Details
-
ClickHelperAction
public ClickHelperAction()
-
-
Method Details
-
clickAndExpect
clicks target And waits for expected element to display retries 10 times- Parameters:
target-expected-
-
clickAndExpect
-
clickAndExpectByText
click And expect based on the text value on the element. eg. button with "OK" text- Parameters:
target-text-expected-
-
clickAndExpect
public void clickAndExpect(EnhancedBy target, int index, EnhancedBy expected, boolean mobileRefresh)clicks element based on index And waits for expected element to be displayed- Parameters:
target-index-expected-mobileRefresh- TODO
-
clickAction
click using actions- Parameters:
target-index-
-
clickAndExpect
clicks element based on index And waits for expected element to be displayed- Parameters:
target-index-expected-
-
clickAndExpect
public void clickAndExpect(EnhancedBy target, int index, EnhancedBy expected1, EnhancedBy expected2)click And expect for either element- Parameters:
target-index-expected1-expected2-
-
clickAndExpect
clicks target And waits for expected element to show up also waits for spinner element to be removed from display- Parameters:
target-expected-spinner-
-
clickAndNotExpect
-
clickAndNotExpect
clicks target And waits for expected to not be displayed retries 10 times- Parameters:
target-expected-
-
clickAndWait
clicks target And waits for seconds- Parameters:
target-expected-
-
clickAndWait
clicks target And waits for seconds- Parameters:
target-expected-
-
clickElementLocationBy
Click on an element's specific x,y location- Parameters:
by- by elementx- x offset coordinatey- y offset coordinate
-
clickPoints
public void clickPoints(int x, int y)click at position x, y- Parameters:
x-y-
-
doubleClickPoints
public void doubleClickPoints(int x, int y)double click at position- Parameters:
x-y-
-
doubleClick
double click on element- Parameters:
target-index-
-
rightClick
right click on element at index- Parameters:
target-index-
-
rightClick
public void rightClick(int x, int y)right click on x, y points- Parameters:
x-y-
-
clickElementContinsByText
click element with text containing- Parameters:
by-text-
-
clickAndHold
click And hold element- Parameters:
target-seconds-
-
clickAndHold
click And hold based on element index- Parameters:
target-index-seconds-
-
dragAndDrop
drag And drop from src element to target element- Parameters:
src-target-
-
dragAndDrop
drag And drop from src element to target element- Parameters:
src-target-
-