org.xwiki.appwithinminutes.test.po
Class StaticListItemsEditor

java.lang.Object
  extended by org.xwiki.test.ui.po.BaseElement
      extended by org.xwiki.appwithinminutes.test.po.StaticListItemsEditor

public class StaticListItemsEditor
extends BaseElement

Represents the static list items editor present on the configuration pane of a static list field.

Since:
4.2M1
Version:
$Id: 3fae8e9905b69f1880be3080aeb6e08abe137322 $

Constructor Summary
StaticListItemsEditor(org.openqa.selenium.WebElement container)
          Creates a new instance.
 
Method Summary
 void add(String value, String label)
          Adds a new item with the specified value and label.
 org.openqa.selenium.WebElement getItem(String valueOrLabel)
           
 org.openqa.selenium.WebElement getLabelInput()
           
 org.openqa.selenium.WebElement getValueInput()
           
 void moveBefore(String valueToMove, String beforeValue)
          Reorders list items.
 void remove(String value)
          Removes the item with the specified value.
 void setLabel(String value, String newLabel)
          Changes item label.
 int size()
           
 
Methods inherited from class org.xwiki.test.ui.po.BaseElement
executeJavascript, getDriver, getUtil, makeAlertDialogSilent, makeConfirmDialogSilent, makeElementVisible, makeElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilElementDisappears, waitUntilElementEndsWithAttributeValue, waitUntilElementHasAttributeValue, waitUntilElementHasTextContent, waitUntilElementIsVisible, waitUntilElementsAreVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticListItemsEditor

public StaticListItemsEditor(org.openqa.selenium.WebElement container)
Creates a new instance.

Parameters:
container - the element that wraps the editor
Method Detail

remove

public void remove(String value)
Removes the item with the specified value.

Parameters:
value - the value of the item to be removed

add

public void add(String value,
                String label)
Adds a new item with the specified value and label.

Parameters:
value - item value
label - item label

getValueInput

public org.openqa.selenium.WebElement getValueInput()
Returns:
the text input used to specify the item value

getLabelInput

public org.openqa.selenium.WebElement getLabelInput()
Returns:
the text input used to specify the item label

setLabel

public void setLabel(String value,
                     String newLabel)
Changes item label.

Parameters:
value - item value
newLabel - the new item label

moveBefore

public void moveBefore(String valueToMove,
                       String beforeValue)
Reorders list items.

Parameters:
valueToMove - the value of the item to be moved
beforeValue - the value of the reference item

getItem

public org.openqa.selenium.WebElement getItem(String valueOrLabel)
Parameters:
valueOrLabel - the value of the label of a list item
Returns:
the first list item that has the specified value or label

size

public int size()
Returns:
the number of list items


Copyright © 2004-2013 XWiki. All Rights Reserved.