Class AbstractComponent
java.lang.Object
org.primefaces.selenium.AbstractPrimePageFragment
org.primefaces.selenium.component.base.AbstractComponent
- All Implemented Interfaces:
org.openqa.selenium.SearchContext,org.openqa.selenium.TakesScreenshot,org.openqa.selenium.WebElement,org.openqa.selenium.WrapsElement
- Direct Known Subclasses:
AbstractInputComponent,AbstractMessage,AbstractPageableData,AccordionPanel,BlockUI,Button,CommandButton,ConfirmPopup,Dialog,Link,Messages,OutputLabel,OverlayPanel,Panel,PickList,RadioButton,Schedule,SelectManyCheckbox,SelectOneRadio,Sidebar,SplitButton,TabView,Timeline,Tree
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddestroy()Destroy the widget.Gets the widget by component id JS function.org.json.JSONObjectGets the current widget's configuration e.g.Gets the current widget's configuration e.g.protected booleanisAjaxified(String event) Is the event for the root-element AJAXified?protected booleanisAjaxified(org.openqa.selenium.WebElement element, String event) Is the event AJAXified?Methods inherited from class org.primefaces.selenium.AbstractPrimePageFragment
getElementLocator, getId, getRoot, getWebDriver, getWrappedElement, setElementLocator, setWebDriverMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.openqa.selenium.TakesScreenshot
getScreenshotAsMethods inherited from interface org.openqa.selenium.WebElement
clear, click, findElement, findElements, getAccessibleName, getAriaRole, getAttribute, getCssValue, getDomAttribute, getDomProperty, getLocation, getRect, getShadowRoot, getSize, getTagName, getText, isDisplayed, isEnabled, isSelected, sendKeys, submit
-
Constructor Details
-
AbstractComponent
public AbstractComponent()
-
-
Method Details
-
getWidgetByIdScript
Gets the widget by component id JS function.- Returns:
- the JS script
-
getWidgetConfigurationAsString
Gets the current widget's configuration e.g. widget.cfg as a String.- Returns:
- the String representation of the widget configuration
-
getWidgetConfiguration
public org.json.JSONObject getWidgetConfiguration()Gets the current widget's configuration e.g. widget.cfg as a JSON object.- Returns:
- the
JSONObjectrepresenting the config, useful for assertions
-
isAjaxified
Is the event for the root-element AJAXified?- Parameters:
event- Event with the `on` prefix, such as `onclick` or `onblur`.- Returns:
- true if using AJAX false if not
-
isAjaxified
Is the event AJAXified?- Parameters:
element- Element for which to do the check. (May be a child element of a complex component.) If no element is passed it defaults to getRoot().event- Event with the `on` prefix, such as `onclick` or `onblur`.- Returns:
- true is using AJAX false it not
-
destroy
public void destroy()Destroy the widget.
-