Package org.xwiki.ckeditor.test.po
Class RichTextAreaElement
- java.lang.Object
-
- org.xwiki.test.ui.po.BaseElement
-
- org.xwiki.ckeditor.test.po.RichTextAreaElement
-
@Unstable public class RichTextAreaElement extends BaseElement
Represents the editing area of a WYSIWYG editor.- Since:
- 1.19
- Version:
- $Id: 6bdfd1dae1491681a4f010bc3d1c043ec0ad0362 $
-
-
Constructor Summary
Constructors Constructor Description RichTextAreaElement(org.openqa.selenium.WebElement iframe)
Creates a new rich text area element.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
Clears the content of the rich text area.void
click()
Clicks on the rich text area.Object
executeScript(String script, Object... arguments)
Executes the given script in the context of the rich text area.String
getContent()
String
getText()
void
sendKeys(CharSequence... keysToSend)
Simulate typing in the rich text area.void
setContent(String content)
Sets the HTML content of the rich text area.-
Methods inherited from class org.xwiki.test.ui.po.BaseElement
getDriver, getUtil, isElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationInProgressMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilPageIsReady
-
-
-
-
Method Detail
-
getText
public String getText()
- Returns:
- the inner text of the rich text area
-
clear
public void clear()
Clears the content of the rich text area.
-
click
public void click()
Clicks on the rich text area.
-
sendKeys
public void sendKeys(CharSequence... keysToSend)
Simulate typing in the rich text area.- Parameters:
keysToSend
- the sequence of keys to by typed
-
executeScript
public Object executeScript(String script, Object... arguments)
Executes the given script in the context of the rich text area.- Parameters:
script
- the script to be executedarguments
- the script arguments- Returns:
- the result of the script execution
- See Also:
JavascriptExecutor.executeScript(String, Object...)
-
getContent
public String getContent()
- Returns:
- the HTML content of the rich text area
-
setContent
public void setContent(String content)
Sets the HTML content of the rich text area.- Parameters:
content
- the new HTML content
-
-