org.uispec4j
Class ListBox
java.lang.Object
org.uispec4j.AbstractUIComponent
org.uispec4j.AbstractSwingUIComponent
org.uispec4j.ListBox
- All Implemented Interfaces:
- TooltipComponent, UIComponent
public class ListBox
- extends AbstractSwingUIComponent
Wrapper for JList components.
This class provides means for checking the contents and selection of the list,
changing the selection, etc. For all these methods, when using String values,
the means of retrieving a String representation of the displayed values can be customized
using the setCellValueConverter(ListBoxCellValueConverter) method and providing
a new ListBoxCellValueConverter implementation.
A DefaultListBoxCellValueConverter is set up by default.
|
Constructor Summary |
ListBox(javax.swing.JList list)
|
| Methods inherited from class org.uispec4j.AbstractUIComponent |
addAttributes, backgroundEquals, backgroundNear, foregroundEquals, foregroundNear, getContainer, getContainer, getDescription, getDescription, getLabel, getName, getSubDescription, isEnabled, isVisible |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TYPE_NAME
public static final java.lang.String TYPE_NAME
- See Also:
- Constant Field Values
SWING_CLASSES
public static final java.lang.Class[] SWING_CLASSES
ListBox
public ListBox(javax.swing.JList list)
getDescriptionTypeName
public java.lang.String getDescriptionTypeName()
- Description copied from interface:
UIComponent
- Returns the name of the component as it will appear in the XML representation
returned by
UIComponent.getDescription().
getAwtComponent
public javax.swing.JList getAwtComponent()
- Description copied from interface:
UIComponent
- Returns the Java GUI component represented by this object.
- Specified by:
getAwtComponent in interface UIComponent- Specified by:
getAwtComponent in class AbstractSwingUIComponent
setCellValueConverter
public void setCellValueConverter(ListBoxCellValueConverter cellValueConverter)
isEmpty
public Assertion isEmpty()
contentEquals
public Assertion contentEquals(java.lang.String... displayedValues)
contains
public Assertion contains(java.lang.String item)
contains
public Assertion contains(java.lang.String... items)
selectIndex
public void selectIndex(int index)
selectIndices
public void selectIndices(int... indices)
select
public void select(java.lang.String... values)
clearSelection
public void clearSelection()
getSize
public int getSize()
doubleClick
public void doubleClick()
selectionIsEmpty
public Assertion selectionIsEmpty()
selectionEquals
public Assertion selectionEquals(java.lang.String... items)
pressKey
public void pressKey(Key key)
Copyright © 2004-2008. All Rights Reserved.