Class JListOperator
java.lang.Object
org.netbeans.jemmy.operators.Operator
org.netbeans.jemmy.operators.ComponentOperator
org.netbeans.jemmy.operators.ContainerOperator
org.netbeans.jemmy.operators.JComponentOperator
org.netbeans.jemmy.operators.JListOperator
- All Implemented Interfaces:
Outputable, Timeoutable
Timeouts used:
ComponentOperator.WaitComponentTimeout - time to wait component displayed
ComponentOperator.WaitStateTimeout - time to wait for item, and for item to be selected
JScrollBarOperator.OneScrollClickTimeout - time for one scroll click
JScrollBarOperator.WholeScrollTimeout - time for the whole scrolling
.
- Author:
- Alexandre Iline (alexandre.iline@sun.com)
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAllows to find component by an item.static classChecks component type.static interfaceIterface to choose list item.classCan be throught during item selecting if list does not have item requested.Nested classes/interfaces inherited from class JComponentOperator
JComponentOperator.JComponentByTipFinder, JComponentOperator.JComponentFinderNested classes/interfaces inherited from class ContainerOperator
ContainerOperator.ContainerFinderNested classes/interfaces inherited from class Operator
Operator.ComponentVisualizer, Operator.DefaultPathParser, Operator.DefaultStringComparator, Operator.Finder, Operator.MapAction, Operator.MapBooleanAction, Operator.MapByteAction, Operator.MapCharacterAction, Operator.MapDoubleAction, Operator.MapFloatAction, Operator.MapIntegerAction, Operator.MapLongAction, Operator.MapVoidAction, Operator.NoBlockingAction, Operator.PathParser, Operator.StringComparator -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringIdentifier for a "item" properties.static final StringIdentifier for a "selected item" property.Fields inherited from class JComponentOperator
A11Y_DATA, A11Y_DESCRIPTION_DPROP, A11Y_NAME_DPROP, TOOLTIP_TEXT_DPROPFields inherited from class ComponentOperator
HEIGHT_DPROP, IS_SHOWING_DPROP, IS_VISIBLE_DPROP, NAME_DPROP, WIDTH_DPROP, X_DPROP, Y_DPROPFields inherited from class Operator
CLASS_DPROP, TO_STRING_DPROP -
Constructor Summary
ConstructorsConstructorDescriptionConstructor.Constructor.JListOperator(ContainerOperator cont, int index) Constructor.JListOperator(ContainerOperator cont, String text) Constructor.JListOperator(ContainerOperator cont, String text, int index) Constructor.JListOperator(ContainerOperator cont, String text, int itemIndex, int index) Constructor.JListOperator(ContainerOperator cont, ComponentChooser chooser) Constructs a JListOperator object.JListOperator(ContainerOperator cont, ComponentChooser chooser, int index) Constructs a JListOperator object. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddListSelectionListener(ListSelectionListener listSelectionListener) MapsJList.addListSelectionListener(ListSelectionListener)through queuevoidaddSelectionInterval(int i, int i1) MapsJList.addSelectionInterval(int, int)through queuevoidMapsJList.clearSelection()through queueclickOnItem(int itemIndex, int clickCount) Clicks on item by item index.clickOnItem(String item) Finds item by item text, and do simple mouse click on it.clickOnItem(String item, boolean ce, boolean cc) Deprecated.Use clickOnItem(String) or clickOnItem(String, StringComparator)clickOnItem(String item, boolean ce, boolean cc, int clickCount) Deprecated.Use clickOnItem(String, int) or clickOnItem(String, StringComparator, int)clickOnItem(String item, int clickCount) Finds item by item text, and do mouse click on it.clickOnItem(String item, Operator.StringComparator comparator) Finds item by item text, and do simple mouse click on it.clickOnItem(String item, Operator.StringComparator comparator, int clickCount) Finds item by item text, and do mouse click on it.voidcopyEnvironment(Operator anotherOperator) Copies all environment (output, timeouts, visualizer) from another operator.voidensureIndexIsVisible(int i) MapsJList.ensureIndexIsVisible(int)through queueintfindItemIndex(String item) Searched for first item by text.intfindItemIndex(String item, boolean ce, boolean cc) Deprecated.Use findItemIndex(String) or findItemIndex(String, StringComparator)intfindItemIndex(String item, boolean ce, boolean cc, int index) Deprecated.Use findItemIndex(String, int) or findItemIndex(String, StringComparator, int)intfindItemIndex(String item, int index) Searched for index'th item by text.intfindItemIndex(String item, Operator.StringComparator comparator) Searches for an item good from chooser's point of view.intfindItemIndex(String item, Operator.StringComparator comparator, int index) Searches for an item good from chooser's point of view.intfindItemIndex(ComponentChooser chooser) Searches for an item by rendered component.intfindItemIndex(ComponentChooser chooser, int index) Searches for index'th item by rendered component.intSearches for an item good from chooser's point of view.intfindItemIndex(JListOperator.ListItemChooser chooser, int index) Searches for index'th item good from chooser's point of view.static JListSearches JList by item.static JListSearches JList by item.static JListfindJList(Container cont, ComponentChooser chooser) Searches 0'th JList in container.static JListfindJList(Container cont, ComponentChooser chooser, int index) Searches JList in container.intMapsJList.getAnchorSelectionIndex()through queuegetCellBounds(int i, int i1) MapsJList.getCellBounds(int, int)through queueMapsJList.getCellRenderer()through queuegetClickPoint(int itemIndex) Gets point to click on itemIndex'th item.getDump()Returns information about component.intMapsJList.getFirstVisibleIndex()through queueintMapsJList.getFixedCellHeight()through queueintMapsJList.getFixedCellWidth()through queueintMapsJList.getLastVisibleIndex()through queueintMapsJList.getLeadSelectionIndex()through queueintMapsJList.getMaxSelectionIndex()through queueintMapsJList.getMinSelectionIndex()through queuegetModel()MapsJList.getModel()through queueReturns print output streams or writers.MapsJList.getPreferredScrollableViewportSize()through queueMapsJList.getPrototypeCellValue()through queuegetRenderedComponent(int itemIndex) Ask renderer for component to be displayed.getRenderedComponent(int itemIndex, boolean isSelected, boolean cellHasFocus) Ask renderer for component to be displayed.intgetScrollableBlockIncrement(Rectangle rectangle, int i, int i1) MapsJList.getScrollableBlockIncrement(Rectangle, int, int)through queuebooleanMapsJList.getScrollableTracksViewportHeight()through queuebooleanMapsJList.getScrollableTracksViewportWidth()through queueintgetScrollableUnitIncrement(Rectangle rectangle, int i, int i1) MapsJList.getScrollableUnitIncrement(Rectangle, int, int)through queueintMapsJList.getSelectedIndex()through queueint[]MapsJList.getSelectedIndices()through queueMapsJList.getSelectedValue()through queueObject[]MapsJList.getSelectedValues()through queueMapsJList.getSelectionBackground()through queueMapsJList.getSelectionForeground()through queueintMapsJList.getSelectionMode()through queueMapsJList.getSelectionModel()through queuegetUI()MapsJList.getUI()through queuebooleanMapsJList.getValueIsAdjusting()through queueintMapsJList.getVisibleRowCount()through queueindexToLocation(int i) MapsJList.indexToLocation(int)through queuebooleanisSelectedIndex(int i) MapsJList.isSelectedIndex(int)through queuebooleanMapsJList.isSelectionEmpty()through queueintlocationToIndex(Point point) MapsJList.locationToIndex(Point)through queuevoidremoveListSelectionListener(ListSelectionListener listSelectionListener) MapsJList.removeListSelectionListener(ListSelectionListener)through queuevoidremoveSelectionInterval(int i, int i1) MapsJList.removeSelectionInterval(int, int)through queuevoidscrollToItem(int itemIndex) Scrolls to an item if the list is on a JScrollPane component.voidscrollToItem(String item, boolean ce, boolean cc) Deprecated.Use scrollToItem(String) or scrollToItem(String, StringComparator)voidscrollToItem(String item, Operator.StringComparator comparator) Scrolls to an item if the list is on a JScrollPane component.voidselectItem(int index) Selects an item by index.voidselectItem(String item) Selects an item by text.voidselectItem(String[] items) Selects items by texts.voidselectItems(int[] indices) Selects items by indices.voidsetCellRenderer(ListCellRenderer listCellRenderer) MapsJList.setCellRenderer(ListCellRenderer)through queuevoidsetFixedCellHeight(int i) MapsJList.setFixedCellHeight(int)through queuevoidsetFixedCellWidth(int i) MapsJList.setFixedCellWidth(int)through queuevoidsetListData(Object[] object) MapsJList.setListData(Object[])through queuevoidsetListData(Vector vector) MapsJList.setListData(Vector)through queuevoidMapsJList.setModel(ListModel)through queuevoid/////////////////////////////////////////////////////voidsetPrototypeCellValue(Object object) MapsJList.setPrototypeCellValue(Object)through queuevoidsetSelectedIndex(int i) MapsJList.setSelectedIndex(int)through queuevoidsetSelectedIndices(int[] i) MapsJList.setSelectedIndices(int[])through queuevoidsetSelectedValue(Object object, boolean b) MapsJList.setSelectedValue(Object, boolean)through queuevoidsetSelectionBackground(Color color) MapsJList.setSelectionBackground(Color)through queuevoidsetSelectionForeground(Color color) MapsJList.setSelectionForeground(Color)through queuevoidsetSelectionInterval(int i, int i1) MapsJList.setSelectionInterval(int, int)through queuevoidsetSelectionMode(int i) MapsJList.setSelectionMode(int)through queuevoidsetSelectionModel(ListSelectionModel listSelectionModel) MapsJList.setSelectionModel(ListSelectionModel)through queuevoidMapsJList.setUI(ListUI)through queuevoidsetValueIsAdjusting(boolean b) MapsJList.setValueIsAdjusting(boolean)through queuevoidsetVisibleRowCount(int i) MapsJList.setVisibleRowCount(int)through queuevoidWaits for item.voidwaitItemSelection(int itemIndex, boolean selected) Waits for item to be selected.voidwaitItemsSelection(int[] itemIndices, boolean selected) Waits for items to be selected.static JListWaits JList by item.static JListWaits JList by item.static JListwaitJList(Container cont, ComponentChooser chooser) Waits 0'th JList in container.static JListwaitJList(Container cont, ComponentChooser chooser, int index) Waits JList in container.Methods inherited from class JComponentOperator
addAncestorListener, addVetoableChangeListener, computeVisibleRect, createToolTip, findJComponent, findJComponent, findJComponent, findJComponent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getActionForKeyStroke, getAutoscrolls, getBorder, getCenterXForClick, getCenterYForClick, getClientProperty, getConditionForKeyStroke, getDebugGraphicsOptions, getInsets, getNextFocusableComponent, getRegisteredKeyStrokes, getRootPane, getTimeouts, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getUIClassID, getVisibleRect, getWindowContainerOperator, grabFocus, isFocusCycleRoot, isManagingFocus, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintImmediately, paintImmediately, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, requestDefaultFocus, resetKeyboardActions, revalidate, scrollRectToVisible, setAlignmentX, setAlignmentY, setAutoscrolls, setBorder, setDebugGraphicsOptions, setDoubleBuffered, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setTimeouts, setToolTipText, showToolTip, unregisterKeyboardAction, updateUI, waitJComponent, waitJComponent, waitJComponent, waitJComponent, waitToolTipMethods inherited from class ContainerOperator
add, add, add, add, add, addContainerListener, createSubOperator, createSubOperator, findComponentAt, findComponentAt, findContainer, findContainer, findContainer, findContainer, findContainerUnder, findContainerUnder, findSubComponent, findSubComponent, getComponent, getComponentCount, getComponents, getInsets, getLayout, isAncestorOf, paintComponents, printComponents, remove, remove, removeAll, removeContainerListener, setLayout, waitContainer, waitContainer, waitContainer, waitContainer, waitSubComponent, waitSubComponentMethods inherited from class ComponentOperator
activateWindow, add, addComponentListener, addFocusListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, checkImage, checkImage, clickForPopup, clickForPopup, clickForPopup, clickForPopup, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, contains, contains, createImage, createImage, dispatchEvent, doLayout, dragMouse, dragMouse, dragMouse, dragNDrop, dragNDrop, dragNDrop, enableInputMethods, enterMouse, exitMouse, findComponent, findComponent, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getCenterX, getCenterY, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getContainer, getContainers, getCursor, getDropTarget, getEventDispatcher, getFocus, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getParent, getPreferredSize, getSize, getSize, getSource, getToolkit, getTreeLock, getWidth, getWindow, getX, getY, hasFocus, imageUpdate, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, isVisible, list, list, list, list, list, makeComponentVisible, moveMouse, paint, paintAll, prepareImage, prepareImage, pressKey, pressKey, pressMouse, pressMouse, print, printAll, pushKey, pushKey, releaseKey, releaseKey, releaseMouse, releaseMouse, remove, removeComponentListener, removeFocusListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFont, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, transferFocus, typeKey, typeKey, typeKey, update, validate, waitComponent, waitComponent, waitComponent, waitComponent, waitComponentEnabled, waitComponentShowing, waitComponentVisible, waitHasFocus, wtComponentEnabledMethods inherited from class Operator
addOperatorPackage, addToDump, addToDump, createOperator, getCharBindingMap, getCharKey, getCharModifiers, getCharsKeys, getCharsKeys, getCharsModifiers, getCharsModifiers, getComparator, getDefaultComponentVisualizer, getDefaultMouseButton, getDefaultPathParser, getDefaultStringComparator, getDefaultVerification, getEnvironmentOperator, getParentPath, getParentPath, getPathParser, getPopupMouseButton, getProperties, getQueueTool, getVerification, getVisualizer, isCaptionEqual, isCaptionEqual, isCaptionEqual, lockQueue, parseString, parseString, printDump, produceNoBlocking, produceNoBlocking, produceTimeRestricted, produceTimeRestricted, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, setCharBindingMap, setComparator, setDefaultComponentVisualizer, setDefaultPathParser, setDefaultStringComparator, setDefaultVerification, setPathParser, setProperties, setVerification, setVisualizer, toStringSource, unlockAndThrow, unlockQueue, waitState
-
Field Details
-
ITEM_PREFIX_DPROP
-
SELECTED_ITEM_PREFIX_DPROP
Identifier for a "selected item" property.- See Also:
-
-
Constructor Details
-
JListOperator
-
JListOperator
Constructs a JListOperator object.- Parameters:
cont- a containerchooser- a component chooser specifying searching criteria.index- an index between appropriate ones.
-
JListOperator
Constructs a JListOperator object.- Parameters:
cont- a containerchooser- a component chooser specifying searching criteria.
-
JListOperator
Constructor. Waits item text first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont- a containertext- Text of item which is currently selected.itemIndex- Item index.index- Ordinal component index.
-
JListOperator
Constructor. Waits component by selected item text first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont- a containertext- Text of item which is currently selected.index- Ordinal component index.- See Also:
-
JListOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont- a containertext- Text of item which is currently selected.- See Also:
-
JListOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont- a containerindex- Ordinal component index.
-
JListOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont- a container
-
-
Method Details
-
findJList
Searches JList in container.- Parameters:
cont- Container to search component in.chooser- org.netbeans.jemmy.ComponentChooser implementation.index- Ordinal component index.- Returns:
- JList instance or null if component was not found.
-
findJList
Searches 0'th JList in container.- Parameters:
cont- Container to search component in.chooser- org.netbeans.jemmy.ComponentChooser implementation.- Returns:
- JList instance or null if component was not found.
-
findJList
public static JList findJList(Container cont, String text, boolean ce, boolean ccs, int itemIndex, int index) Searches JList by item.- Parameters:
cont- Container to search component in.text- Item text. If null, contents is not checked.ce- Compare text exactly.ccs- Compare text case sensitively.itemIndex- Index of item to compare text. If -1, selected item is checked.index- Ordinal component index.- Returns:
- JList instance or null if component was not found.
- See Also:
-
findJList
Searches JList by item.- Parameters:
cont- Container to search component in.text- Item text. If null, contents is not checked.ce- Compare text exactly.ccs- Compare text case sensitively.itemIndex- Index of item to compare text. If -1, selected item is checked.- Returns:
- JList instance or null if component was not found.
- See Also:
-
waitJList
Waits JList in container.- Parameters:
cont- Container to search component in.chooser- org.netbeans.jemmy.ComponentChooser implementation.index- Ordinal component index.- Returns:
- JList instance or null if component was not found.
-
waitJList
Waits 0'th JList in container.- Parameters:
cont- Container to search component in.chooser- org.netbeans.jemmy.ComponentChooser implementation.- Returns:
- JList instance or null if component was not found.
-
waitJList
public static JList waitJList(Container cont, String text, boolean ce, boolean ccs, int itemIndex, int index) Waits JList by item.- Parameters:
cont- Container to search component in.text- Item text. If null, contents is not checked.ce- Compare text exactly.ccs- Compare text case sensitively.itemIndex- Index of item to compare text. If -1, selected item is checked.index- Ordinal component index.- Returns:
- JList instance or null if component was not found.
- See Also:
-
waitJList
Waits JList by item.- Parameters:
cont- Container to search component in.text- Item text. If null, contents is not checked.ce- Compare text exactly.ccs- Compare text case sensitively.itemIndex- Index of item to compare text. If -1, selected item is checked.- Returns:
- JList instance or null if component was not found.
- See Also:
-
setOutput
Description copied from class:ComponentOperator/////////////////////////////////////////////////////- Specified by:
setOutputin interfaceOutputable- Overrides:
setOutputin classJComponentOperator- Parameters:
output- Identify the streams or writers used for print output.- See Also:
-
getOutput
Description copied from interface:OutputableReturns print output streams or writers.- Specified by:
getOutputin interfaceOutputable- Overrides:
getOutputin classJComponentOperator- Returns:
- an object that contains references to objects for printing to output and err streams.
- See Also:
-
copyEnvironment
Description copied from class:OperatorCopies all environment (output, timeouts, visualizer) from another operator.- Overrides:
copyEnvironmentin classComponentOperator- Parameters:
anotherOperator- an operator to copy the environment to.
-
getClickPoint
Gets point to click on itemIndex'th item.- Parameters:
itemIndex- an index of an item to click.- Returns:
- a Point in component's coordinate system.
-
getRenderedComponent
Ask renderer for component to be displayed.- Parameters:
itemIndex- Item index.isSelected- True if the specified cell was selected.cellHasFocus- True if the specified cell has the focus.- Returns:
- Component to be displayed.
-
getRenderedComponent
Ask renderer for component to be displayed. Uses isSelectedIndex(itemIndex) to determine whether item is selected. Supposes item do not have focus.- Parameters:
itemIndex- Item index.- Returns:
- Component to be displayed.
-
findItemIndex
Searches for index'th item good from chooser's point of view.- Parameters:
chooser- Item verifying object.index- Ordinal item index.- Returns:
- Item index or -1 if search was insuccessful.
-
findItemIndex
Searches for an item good from chooser's point of view.- Parameters:
chooser- Item verifying object.- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
findItemIndex
Searches for an item good from chooser's point of view.- Parameters:
item- a text patterncomparator- a string comparision algorithmindex- Ordinal item index.- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
findItemIndex
Deprecated.Use findItemIndex(String, int) or findItemIndex(String, StringComparator, int)Searched for index'th item by text.- Parameters:
item- a text patternce- Compare text exactly.cc- Compare text case sensitively.index- Ordinal item index.- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
findItemIndex
Searched for index'th item by text. Uses StringComparator assigned to this object.- Parameters:
item- a text patternindex- Ordinal item index.- Returns:
- Item index or -1 if search was insuccessful.
-
findItemIndex
Searches for an item good from chooser's point of view.- Parameters:
item- a text patterncomparator- a string comparision algorithm- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
findItemIndex
Deprecated.Use findItemIndex(String) or findItemIndex(String, StringComparator)Searched item by text.- Parameters:
item- a text patternce- Compare text exactly.cc- Compare text case sensitively.- Returns:
- Item index or -1 if search was insuccessful.
- See Also:
-
findItemIndex
Searched for first item by text. Uses StringComparator assigned to this object.- Parameters:
item- a text pattern- Returns:
- Item index or -1 if search was insuccessful.
- See Also:
-
findItemIndex
Searches for index'th item by rendered component.- Parameters:
chooser- Component verifying object.index- Ordinal item index.- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
findItemIndex
Searches for an item by rendered component.- Parameters:
chooser- Component verifying object.- Returns:
- Item index or -1 if serch was insuccessful.
- See Also:
-
clickOnItem
Clicks on item by item index.- Parameters:
itemIndex- Item index.clickCount- count click.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Finds item by item text, and do mouse click on it.- Parameters:
item- Item text.comparator- a string comparision algorithmclickCount- count click.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Deprecated.Use clickOnItem(String, int) or clickOnItem(String, StringComparator, int)Finds item by item text, and do mouse click on it.- Parameters:
item- Item text.ce- Compare exactly.cc- Compare case sensitively.clickCount- count click.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Finds item by item text, and do mouse click on it. Uses StringComparator assigned to this object.- Parameters:
item- Item text.clickCount- count click.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Finds item by item text, and do simple mouse click on it. Uses StringComparator assigned to this object.- Parameters:
item- Item text.comparator- a string comparision algorithm- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Deprecated.Use clickOnItem(String) or clickOnItem(String, StringComparator)Finds item by item text, and do simple mouse click on it.- Parameters:
item- Item text.ce- Compare exactly.cc- Compare case sensitively.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
clickOnItem
Finds item by item text, and do simple mouse click on it. Uses StringComparator assigned to this object.- Parameters:
item- Item text.- Returns:
- Click point or null if list does not contains itemIndex'th item.
- Throws:
JListOperator.NoSuchItemException
-
scrollToItem
public void scrollToItem(int itemIndex) Scrolls to an item if the list is on a JScrollPane component.- Parameters:
itemIndex- an item index.- Throws:
JListOperator.NoSuchItemException- See Also:
-
scrollToItem
Scrolls to an item if the list is on a JScrollPane component.- Parameters:
item- Item textcomparator- a string comparision algorithm- See Also:
-
scrollToItem
Deprecated.Use scrollToItem(String) or scrollToItem(String, StringComparator)Scrolls to an item if the list is on a JScrollPane component.- Parameters:
item- Item textce- Compare exactly.cc- Compare case sensitively.- See Also:
-
selectItem
public void selectItem(int index) Selects an item by index.- Parameters:
index- an item index.
-
selectItem
-
selectItems
public void selectItems(int[] indices) Selects items by indices.- Parameters:
indices- item indices.
-
selectItem
-
waitItemsSelection
public void waitItemsSelection(int[] itemIndices, boolean selected) Waits for items to be selected.- Parameters:
itemIndices- item indices to be selectedselected- Selected (true) or unselected (false).
-
waitItemSelection
public void waitItemSelection(int itemIndex, boolean selected) Waits for item to be selected.- Parameters:
itemIndex- an item needs to be selectedselected- Selected (true) or unselected (false).
-
waitItem
Waits for item. Uses getComparator() comparator.- Parameters:
item- an item textitemIndex- Index of item to check or -1 to check selected item.
-
getDump
Returns information about component.- Overrides:
getDumpin classJComponentOperator- Returns:
- a Hashtable containing name-value pairs.
-
addListSelectionListener
MapsJList.addListSelectionListener(ListSelectionListener)through queue -
addSelectionInterval
public void addSelectionInterval(int i, int i1) MapsJList.addSelectionInterval(int, int)through queue -
clearSelection
public void clearSelection()MapsJList.clearSelection()through queue -
ensureIndexIsVisible
public void ensureIndexIsVisible(int i) MapsJList.ensureIndexIsVisible(int)through queue -
getAnchorSelectionIndex
public int getAnchorSelectionIndex()MapsJList.getAnchorSelectionIndex()through queue -
getCellBounds
MapsJList.getCellBounds(int, int)through queue -
getCellRenderer
MapsJList.getCellRenderer()through queue -
getFirstVisibleIndex
public int getFirstVisibleIndex()MapsJList.getFirstVisibleIndex()through queue -
getFixedCellHeight
public int getFixedCellHeight()MapsJList.getFixedCellHeight()through queue -
getFixedCellWidth
public int getFixedCellWidth()MapsJList.getFixedCellWidth()through queue -
getLastVisibleIndex
public int getLastVisibleIndex()MapsJList.getLastVisibleIndex()through queue -
getLeadSelectionIndex
public int getLeadSelectionIndex()MapsJList.getLeadSelectionIndex()through queue -
getMaxSelectionIndex
public int getMaxSelectionIndex()MapsJList.getMaxSelectionIndex()through queue -
getMinSelectionIndex
public int getMinSelectionIndex()MapsJList.getMinSelectionIndex()through queue -
getModel
MapsJList.getModel()through queue -
getPreferredScrollableViewportSize
MapsJList.getPreferredScrollableViewportSize()through queue -
getPrototypeCellValue
MapsJList.getPrototypeCellValue()through queue -
getScrollableBlockIncrement
MapsJList.getScrollableBlockIncrement(Rectangle, int, int)through queue -
getScrollableTracksViewportHeight
public boolean getScrollableTracksViewportHeight()MapsJList.getScrollableTracksViewportHeight()through queue -
getScrollableTracksViewportWidth
public boolean getScrollableTracksViewportWidth()MapsJList.getScrollableTracksViewportWidth()through queue -
getScrollableUnitIncrement
MapsJList.getScrollableUnitIncrement(Rectangle, int, int)through queue -
getSelectedIndex
public int getSelectedIndex()MapsJList.getSelectedIndex()through queue -
getSelectedIndices
public int[] getSelectedIndices()MapsJList.getSelectedIndices()through queue -
getSelectedValue
MapsJList.getSelectedValue()through queue -
getSelectedValues
MapsJList.getSelectedValues()through queue -
getSelectionBackground
MapsJList.getSelectionBackground()through queue -
getSelectionForeground
MapsJList.getSelectionForeground()through queue -
getSelectionMode
public int getSelectionMode()MapsJList.getSelectionMode()through queue -
getSelectionModel
MapsJList.getSelectionModel()through queue -
getUI
MapsJList.getUI()through queue -
getValueIsAdjusting
public boolean getValueIsAdjusting()MapsJList.getValueIsAdjusting()through queue -
getVisibleRowCount
public int getVisibleRowCount()MapsJList.getVisibleRowCount()through queue -
indexToLocation
MapsJList.indexToLocation(int)through queue -
isSelectedIndex
public boolean isSelectedIndex(int i) MapsJList.isSelectedIndex(int)through queue -
isSelectionEmpty
public boolean isSelectionEmpty()MapsJList.isSelectionEmpty()through queue -
locationToIndex
MapsJList.locationToIndex(Point)through queue -
removeListSelectionListener
MapsJList.removeListSelectionListener(ListSelectionListener)through queue -
removeSelectionInterval
public void removeSelectionInterval(int i, int i1) MapsJList.removeSelectionInterval(int, int)through queue -
setCellRenderer
MapsJList.setCellRenderer(ListCellRenderer)through queue -
setFixedCellHeight
public void setFixedCellHeight(int i) MapsJList.setFixedCellHeight(int)through queue -
setFixedCellWidth
public void setFixedCellWidth(int i) MapsJList.setFixedCellWidth(int)through queue -
setListData
MapsJList.setListData(Vector)through queue -
setListData
MapsJList.setListData(Object[])through queue -
setModel
MapsJList.setModel(ListModel)through queue -
setPrototypeCellValue
MapsJList.setPrototypeCellValue(Object)through queue -
setSelectedIndex
public void setSelectedIndex(int i) MapsJList.setSelectedIndex(int)through queue -
setSelectedIndices
public void setSelectedIndices(int[] i) MapsJList.setSelectedIndices(int[])through queue -
setSelectedValue
MapsJList.setSelectedValue(Object, boolean)through queue -
setSelectionBackground
MapsJList.setSelectionBackground(Color)through queue -
setSelectionForeground
MapsJList.setSelectionForeground(Color)through queue -
setSelectionInterval
public void setSelectionInterval(int i, int i1) MapsJList.setSelectionInterval(int, int)through queue -
setSelectionMode
public void setSelectionMode(int i) MapsJList.setSelectionMode(int)through queue -
setSelectionModel
MapsJList.setSelectionModel(ListSelectionModel)through queue -
setUI
MapsJList.setUI(ListUI)through queue -
setValueIsAdjusting
public void setValueIsAdjusting(boolean b) MapsJList.setValueIsAdjusting(boolean)through queue -
setVisibleRowCount
public void setVisibleRowCount(int i) MapsJList.setVisibleRowCount(int)through queue
-